Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
6baaf13f
V
vscode
项目概览
xxadev
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
6baaf13f
编写于
7月 06, 2016
作者:
B
Benjamin Pasero
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Revert "more fixes for #8578"
This reverts commit
fa7ce995
.
上级
1920059e
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
23 addition
and
25 deletion
+23
-25
src/vs/workbench/browser/media/workbench.css
src/vs/workbench/browser/media/workbench.css
+0
-0
src/vs/workbench/browser/workbench.ts
src/vs/workbench/browser/workbench.ts
+0
-0
src/vs/workbench/electron-browser/shell.ts
src/vs/workbench/electron-browser/shell.ts
+1
-1
src/vs/workbench/parts/files/browser/textFileServices.ts
src/vs/workbench/parts/files/browser/textFileServices.ts
+19
-2
src/vs/workbench/parts/files/electron-browser/textFileServices.ts
...orkbench/parts/files/electron-browser/textFileServices.ts
+2
-21
src/vs/workbench/workbench.main.ts
src/vs/workbench/workbench.main.ts
+1
-1
未找到文件。
src/vs/workbench/
electron-
browser/media/workbench.css
→
src/vs/workbench/browser/media/workbench.css
浏览文件 @
6baaf13f
文件已移动
src/vs/workbench/
electron-
browser/workbench.ts
→
src/vs/workbench/browser/workbench.ts
浏览文件 @
6baaf13f
文件已移动
src/vs/workbench/electron-browser/shell.ts
浏览文件 @
6baaf13f
...
...
@@ -17,7 +17,7 @@ import {dispose, IDisposable, Disposables} from 'vs/base/common/lifecycle';
import
errors
=
require
(
'
vs/base/common/errors
'
);
import
{
ContextViewService
}
from
'
vs/platform/contextview/browser/contextViewService
'
;
import
timer
=
require
(
'
vs/base/common/timer
'
);
import
{
Workbench
}
from
'
vs/workbench/
electron-
browser/workbench
'
;
import
{
Workbench
}
from
'
vs/workbench/browser/workbench
'
;
import
{
Storage
,
inMemoryLocalStorageInstance
}
from
'
vs/workbench/common/storage
'
;
import
{
ITelemetryService
,
NullTelemetryService
}
from
'
vs/platform/telemetry/common/telemetry
'
;
import
{
ITelemetryAppenderChannel
,
TelemetryAppenderClient
}
from
'
vs/platform/telemetry/common/telemetryIpc
'
;
...
...
src/vs/workbench/parts/files/browser/textFileServices.ts
浏览文件 @
6baaf13f
...
...
@@ -21,6 +21,7 @@ import {ITelemetryService} from 'vs/platform/telemetry/common/telemetry';
import
{
IDisposable
,
dispose
}
from
'
vs/base/common/lifecycle
'
;
import
{
IWorkbenchEditorService
}
from
'
vs/workbench/services/editor/common/editorService
'
;
import
{
IEditorGroupService
}
from
'
vs/workbench/services/group/common/groupService
'
;
import
{
ModelBuilder
}
from
'
vs/editor/node/model/modelBuilder
'
;
import
{
IModelService
}
from
'
vs/editor/common/services/modelService
'
;
/**
...
...
@@ -48,7 +49,7 @@ export abstract class TextFileService implements ITextFileService {
@
IEditorGroupService
private
editorGroupService
:
IEditorGroupService
,
@
IEventService
private
eventService
:
IEventService
,
@
IFileService
protected
fileService
:
IFileService
,
@
IModelService
pr
otected
modelService
:
IModelService
@
IModelService
pr
ivate
modelService
:
IModelService
)
{
this
.
listenerToUnbind
=
[];
this
.
_onAutoSaveConfigurationChange
=
new
Emitter
<
IAutoSaveConfiguration
>
();
...
...
@@ -63,7 +64,23 @@ export abstract class TextFileService implements ITextFileService {
this
.
telemetryService
.
publicLog
(
'
autoSave
'
,
this
.
getAutoSaveConfiguration
());
}
public
abstract
resolveTextContent
(
resource
:
URI
,
options
?:
IResolveContentOptions
):
TPromise
<
IRawTextContent
>
;
public
resolveTextContent
(
resource
:
URI
,
options
?:
IResolveContentOptions
):
TPromise
<
IRawTextContent
>
{
return
this
.
fileService
.
resolveStreamContent
(
resource
,
options
).
then
((
streamContent
)
=>
{
return
ModelBuilder
.
fromStringStream
(
streamContent
.
value
,
this
.
modelService
.
getCreationOptions
()).
then
((
res
)
=>
{
let
r
:
IRawTextContent
=
{
resource
:
streamContent
.
resource
,
name
:
streamContent
.
name
,
mtime
:
streamContent
.
mtime
,
etag
:
streamContent
.
etag
,
mime
:
streamContent
.
mime
,
encoding
:
streamContent
.
encoding
,
value
:
res
.
rawText
,
valueLogicalHash
:
res
.
hash
};
return
r
;
});
});
}
public
get
onAutoSaveConfigurationChange
():
Event
<
IAutoSaveConfiguration
>
{
return
this
.
_onAutoSaveConfigurationChange
.
event
;
...
...
src/vs/workbench/parts/files/electron-browser/textFileServices.ts
浏览文件 @
6baaf13f
...
...
@@ -16,9 +16,9 @@ import {ConfirmResult} from 'vs/workbench/common/editor';
import
{
IEventService
}
from
'
vs/platform/event/common/event
'
;
import
{
TextFileService
as
AbstractTextFileService
}
from
'
vs/workbench/parts/files/browser/textFileServices
'
;
import
{
CACHE
,
TextFileEditorModel
}
from
'
vs/workbench/parts/files/common/editors/textFileEditorModel
'
;
import
{
ITextFileOperationResult
,
AutoSaveMode
,
IRawTextContent
}
from
'
vs/workbench/parts/files/common/files
'
;
import
{
ITextFileOperationResult
,
AutoSaveMode
}
from
'
vs/workbench/parts/files/common/files
'
;
import
{
IUntitledEditorService
}
from
'
vs/workbench/services/untitled/common/untitledEditorService
'
;
import
{
IFileService
,
IResolveContentOptions
}
from
'
vs/platform/files/common/files
'
;
import
{
IFileService
}
from
'
vs/platform/files/common/files
'
;
import
{
BinaryEditorModel
}
from
'
vs/workbench/common/editor/binaryEditorModel
'
;
import
{
IInstantiationService
}
from
'
vs/platform/instantiation/common/instantiation
'
;
import
{
IWorkspaceContextService
}
from
'
vs/workbench/services/workspace/common/contextService
'
;
...
...
@@ -30,7 +30,6 @@ import {IWorkbenchEditorService} from 'vs/workbench/services/editor/common/edito
import
{
IWindowService
}
from
'
vs/workbench/services/window/electron-browser/windowService
'
;
import
{
IEditorGroupService
}
from
'
vs/workbench/services/group/common/groupService
'
;
import
{
IModelService
}
from
'
vs/editor/common/services/modelService
'
;
import
{
ModelBuilder
}
from
'
vs/editor/node/model/modelBuilder
'
;
export
class
TextFileService
extends
AbstractTextFileService
{
...
...
@@ -64,24 +63,6 @@ export class TextFileService extends AbstractTextFileService {
this
.
lifecycleService
.
onShutdown
(
this
.
onShutdown
,
this
);
}
public
resolveTextContent
(
resource
:
URI
,
options
?:
IResolveContentOptions
):
TPromise
<
IRawTextContent
>
{
return
this
.
fileService
.
resolveStreamContent
(
resource
,
options
).
then
((
streamContent
)
=>
{
return
ModelBuilder
.
fromStringStream
(
streamContent
.
value
,
this
.
modelService
.
getCreationOptions
()).
then
((
res
)
=>
{
let
r
:
IRawTextContent
=
{
resource
:
streamContent
.
resource
,
name
:
streamContent
.
name
,
mtime
:
streamContent
.
mtime
,
etag
:
streamContent
.
etag
,
mime
:
streamContent
.
mime
,
encoding
:
streamContent
.
encoding
,
value
:
res
.
rawText
,
valueLogicalHash
:
res
.
hash
};
return
r
;
});
});
}
public
beforeShutdown
():
boolean
|
TPromise
<
boolean
>
{
// Dirty files need treatment on shutdown
...
...
src/vs/workbench/workbench.main.ts
浏览文件 @
6baaf13f
...
...
@@ -54,7 +54,7 @@ import 'vs/workbench/parts/output/browser/output.contribution';
import
'
vs/workbench/parts/terminal/electron-browser/terminal.contribution
'
;
import
'
vs/workbench/
electron-
browser/workbench
'
;
import
'
vs/workbench/browser/workbench
'
;
import
'
vs/workbench/parts/tasks/electron-browser/task.contribution
'
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录