Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
6829e20b
V
vscode
项目概览
掘金者说
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
6829e20b
编写于
3月 03, 2020
作者:
J
Johannes Rieken
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
es6 - replace some usages of values/keys utils with destructuring
上级
18945092
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
12 addition
and
16 deletion
+12
-16
src/vs/editor/contrib/codelens/codeLensCache.ts
src/vs/editor/contrib/codelens/codeLensCache.ts
+2
-2
src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.ts
...vs/workbench/api/browser/mainThreadDocumentsAndEditors.ts
+2
-3
src/vs/workbench/api/common/extHostDiagnostics.ts
src/vs/workbench/api/common/extHostDiagnostics.ts
+2
-3
src/vs/workbench/api/common/extHostTypes.ts
src/vs/workbench/api/common/extHostTypes.ts
+1
-2
src/vs/workbench/contrib/snippets/browser/configureSnippets.ts
...s/workbench/contrib/snippets/browser/configureSnippets.ts
+1
-2
src/vs/workbench/contrib/snippets/browser/snippets.contribution.ts
...rkbench/contrib/snippets/browser/snippets.contribution.ts
+1
-1
src/vs/workbench/contrib/snippets/browser/snippetsService.ts
src/vs/workbench/contrib/snippets/browser/snippetsService.ts
+3
-3
未找到文件。
src/vs/editor/contrib/codelens/codeLensCache.ts
浏览文件 @
6829e20b
...
...
@@ -7,7 +7,7 @@ import { ITextModel } from 'vs/editor/common/model';
import
{
createDecorator
}
from
'
vs/platform/instantiation/common/instantiation
'
;
import
{
registerSingleton
}
from
'
vs/platform/instantiation/common/extensions
'
;
import
{
CodeLensModel
}
from
'
vs/editor/contrib/codelens/codelens
'
;
import
{
LRUCache
,
values
}
from
'
vs/base/common/map
'
;
import
{
LRUCache
}
from
'
vs/base/common/map
'
;
import
{
CodeLensProvider
,
CodeLensList
,
CodeLens
}
from
'
vs/editor/common/modes
'
;
import
{
IStorageService
,
StorageScope
,
WillSaveStateReason
}
from
'
vs/platform/storage/common/storage
'
;
import
{
Range
}
from
'
vs/editor/common/core/range
'
;
...
...
@@ -103,7 +103,7 @@ export class CodeLensCache implements ICodeLensCache {
}
data
[
key
]
=
{
lineCount
:
value
.
lineCount
,
lines
:
values
(
lines
)
lines
:
[...
lines
.
values
()]
};
});
return
JSON
.
stringify
(
data
);
...
...
src/vs/workbench/api/browser/mainThreadDocumentsAndEditors.ts
浏览文件 @
6829e20b
...
...
@@ -5,7 +5,6 @@
import
{
Emitter
,
Event
}
from
'
vs/base/common/event
'
;
import
{
IDisposable
,
combinedDisposable
,
DisposableStore
}
from
'
vs/base/common/lifecycle
'
;
import
{
values
}
from
'
vs/base/common/map
'
;
import
{
URI
}
from
'
vs/base/common/uri
'
;
import
{
ICodeEditor
,
isCodeEditor
,
isDiffEditor
,
IActiveCodeEditor
}
from
'
vs/editor/browser/editorBrowser
'
;
import
{
IBulkEditService
}
from
'
vs/editor/browser/services/bulkEditService
'
;
...
...
@@ -110,8 +109,8 @@ class DocumentAndEditorState {
static
compute
(
before
:
DocumentAndEditorState
|
undefined
,
after
:
DocumentAndEditorState
):
DocumentAndEditorStateDelta
{
if
(
!
before
)
{
return
new
DocumentAndEditorStateDelta
(
[],
values
(
after
.
documents
)
,
[],
values
(
after
.
textEditors
)
,
[],
[...
after
.
documents
.
values
()]
,
[],
[...
after
.
textEditors
.
values
()]
,
undefined
,
after
.
activeEditor
);
}
...
...
src/vs/workbench/api/common/extHostDiagnostics.ts
浏览文件 @
6829e20b
...
...
@@ -12,7 +12,6 @@ import { DiagnosticSeverity } from './extHostTypes';
import
*
as
converter
from
'
./extHostTypeConverters
'
;
import
{
mergeSort
}
from
'
vs/base/common/arrays
'
;
import
{
Event
,
Emitter
}
from
'
vs/base/common/event
'
;
import
{
keys
}
from
'
vs/base/common/map
'
;
import
{
ILogService
}
from
'
vs/platform/log/common/log
'
;
export
class
DiagnosticCollection
implements
vscode
.
DiagnosticCollection
{
...
...
@@ -36,7 +35,7 @@ export class DiagnosticCollection implements vscode.DiagnosticCollection {
dispose
():
void
{
if
(
!
this
.
_isDisposed
)
{
this
.
_onDidChangeDiagnostics
.
fire
(
keys
(
this
.
_data
)
);
this
.
_onDidChangeDiagnostics
.
fire
(
[...
this
.
_data
.
keys
()]
);
if
(
this
.
_proxy
)
{
this
.
_proxy
.
$clear
(
this
.
_owner
);
}
...
...
@@ -169,7 +168,7 @@ export class DiagnosticCollection implements vscode.DiagnosticCollection {
clear
():
void
{
this
.
_checkDisposed
();
this
.
_onDidChangeDiagnostics
.
fire
(
keys
(
this
.
_data
)
);
this
.
_onDidChangeDiagnostics
.
fire
(
[...
this
.
_data
.
keys
()]
);
this
.
_data
.
clear
();
if
(
this
.
_proxy
)
{
this
.
_proxy
.
$clear
(
this
.
_owner
);
...
...
src/vs/workbench/api/common/extHostTypes.ts
浏览文件 @
6829e20b
...
...
@@ -7,7 +7,6 @@ import { coalesce, equals } from 'vs/base/common/arrays';
import
{
illegalArgument
}
from
'
vs/base/common/errors
'
;
import
{
IRelativePattern
}
from
'
vs/base/common/glob
'
;
import
{
isMarkdownString
}
from
'
vs/base/common/htmlContent
'
;
import
{
values
}
from
'
vs/base/common/map
'
;
import
{
startsWith
}
from
'
vs/base/common/strings
'
;
import
{
URI
}
from
'
vs/base/common/uri
'
;
import
{
generateUuid
}
from
'
vs/base/common/uuid
'
;
...
...
@@ -661,7 +660,7 @@ export class WorkspaceEdit implements vscode.WorkspaceEdit {
textEdit
[
1
].
push
(
candidate
.
edit
);
}
}
return
values
(
textEdits
)
;
return
[...
textEdits
.
values
()]
;
}
allEntries
():
ReadonlyArray
<
IFileTextEdit
|
IFileOperation
>
{
...
...
src/vs/workbench/contrib/snippets/browser/configureSnippets.ts
浏览文件 @
6829e20b
...
...
@@ -12,7 +12,6 @@ import { MenuRegistry, MenuId } from 'vs/platform/actions/common/actions';
import
{
IOpenerService
}
from
'
vs/platform/opener/common/opener
'
;
import
{
URI
}
from
'
vs/base/common/uri
'
;
import
{
ISnippetsService
}
from
'
vs/workbench/contrib/snippets/browser/snippets.contribution
'
;
import
{
values
}
from
'
vs/base/common/map
'
;
import
{
IQuickPickItem
,
IQuickInputService
,
QuickPickInput
}
from
'
vs/platform/quickinput/common/quickInput
'
;
import
{
SnippetSource
}
from
'
vs/workbench/contrib/snippets/browser/snippetsFile
'
;
import
{
IWorkspaceContextService
}
from
'
vs/platform/workspace/common/workspace
'
;
...
...
@@ -73,7 +72,7 @@ async function computePicks(snippetService: ISnippetsService, envService: IEnvir
filepath
:
file
.
location
,
description
:
names
.
size
===
0
?
nls
.
localize
(
'
global.scope
'
,
"
(global)
"
)
:
nls
.
localize
(
'
global.1
'
,
"
({0})
"
,
values
(
names
)
.
join
(
'
,
'
))
:
nls
.
localize
(
'
global.1
'
,
"
({0})
"
,
[...
names
]
.
join
(
'
,
'
))
});
}
else
{
...
...
src/vs/workbench/contrib/snippets/browser/snippets.contribution.ts
浏览文件 @
6829e20b
...
...
@@ -17,7 +17,7 @@ export interface ISnippetsService {
_serviceBrand
:
undefined
;
getSnippetFiles
():
Promise
<
SnippetFile
[]
>
;
getSnippetFiles
():
Promise
<
Iterable
<
SnippetFile
>
>
;
getSnippets
(
languageId
:
LanguageId
):
Promise
<
Snippet
[]
>
;
...
...
src/vs/workbench/contrib/snippets/browser/snippetsService.ts
浏览文件 @
6829e20b
...
...
@@ -5,7 +5,6 @@
import
{
IJSONSchema
}
from
'
vs/base/common/jsonSchema
'
;
import
{
combinedDisposable
,
IDisposable
,
DisposableStore
}
from
'
vs/base/common/lifecycle
'
;
import
{
values
}
from
'
vs/base/common/map
'
;
import
*
as
resources
from
'
vs/base/common/resources
'
;
import
{
endsWith
,
isFalsyOrWhitespace
}
from
'
vs/base/common/strings
'
;
import
{
URI
}
from
'
vs/base/common/uri
'
;
...
...
@@ -162,8 +161,9 @@ class SnippetsService implements ISnippetsService {
return
Promise
.
all
(
promises
);
}
getSnippetFiles
():
Promise
<
SnippetFile
[]
>
{
return
this
.
_joinSnippets
().
then
(()
=>
values
(
this
.
_files
));
async
getSnippetFiles
():
Promise
<
Iterable
<
SnippetFile
>>
{
await
this
.
_joinSnippets
();
return
this
.
_files
.
values
();
}
getSnippets
(
languageId
:
LanguageId
):
Promise
<
Snippet
[]
>
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录