Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
2afb3360
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,发现更多精彩内容 >>
提交
2afb3360
编写于
12月 16, 2017
作者:
R
Ryan Adolf
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Make Linux compatible
上级
8667ae7e
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
6 addition
and
14 deletion
+6
-14
src/vs/code/electron-main/window.ts
src/vs/code/electron-main/window.ts
+2
-2
src/vs/workbench/browser/layout.ts
src/vs/workbench/browser/layout.ts
+1
-1
src/vs/workbench/browser/parts/titlebar/titlebarPart.ts
src/vs/workbench/browser/parts/titlebar/titlebarPart.ts
+2
-2
src/vs/workbench/electron-browser/main.contribution.ts
src/vs/workbench/electron-browser/main.contribution.ts
+1
-2
src/vs/workbench/electron-browser/workbench.ts
src/vs/workbench/electron-browser/workbench.ts
+0
-3
src/vs/workbench/test/workbenchTestServices.ts
src/vs/workbench/test/workbenchTestServices.ts
+0
-4
未找到文件。
src/vs/code/electron-main/window.ts
浏览文件 @
2afb3360
...
...
@@ -174,7 +174,7 @@ export class CodeWindow implements ICodeWindow {
}
let
useCustomTitleStyle
=
false
;
if
((
isWindows
&&
windowConfig
&&
windowConfig
.
titleBarStyle
===
'
custom
'
)
||
if
((
!
isMacintosh
&&
windowConfig
&&
windowConfig
.
titleBarStyle
===
'
custom
'
)
||
(
isMacintosh
&&
(
!
windowConfig
||
!
windowConfig
.
titleBarStyle
||
windowConfig
.
titleBarStyle
===
'
custom
'
)))
{
const
isDev
=
!
this
.
environmentService
.
isBuilt
||
!!
config
.
extensionDevelopmentPath
;
if
(
!
isMacintosh
||
!
isDev
)
{
...
...
@@ -189,7 +189,7 @@ export class CodeWindow implements ICodeWindow {
if
(
useCustomTitleStyle
)
{
options
.
titleBarStyle
=
'
hidden
'
;
this
.
hiddenTitleBarStyle
=
true
;
if
(
isWindows
)
{
if
(
!
isMacintosh
)
{
options
.
frame
=
false
;
}
}
...
...
src/vs/workbench/browser/layout.ts
浏览文件 @
2afb3360
...
...
@@ -783,7 +783,7 @@ export class WorkbenchLayout implements IVerticalSashLayoutProvider, IHorizontal
}
public
onMaximizeChange
(
maximized
:
boolean
):
void
{
if
(
isWindows
)
{
if
(
!
isMacintosh
)
{
this
.
titlebarBaseHeight
=
maximized
?
23
:
this
.
partLayoutInfo
.
titlebar
.
height
;
}
else
{
this
.
titlebarBaseHeight
=
this
.
partLayoutInfo
.
titlebar
.
height
;
...
...
src/vs/workbench/browser/parts/titlebar/titlebarPart.ts
浏览文件 @
2afb3360
...
...
@@ -231,7 +231,7 @@ export class TitlebarPart extends Part implements ITitleService {
const
SVGNS
=
'
http://www.w3.org/2000/svg
'
;
this
.
titleContainer
=
$
(
parent
);
if
(
isWindows
)
{
if
(
!
isMacintosh
)
{
$
(
this
.
titleContainer
).
img
({
class
:
'
window-appicon
'
,
src
:
path
.
join
(
this
.
environmentService
.
appRoot
,
'
resources/linux/code.png
'
)
});
}
...
...
@@ -265,7 +265,7 @@ export class TitlebarPart extends Part implements ITitleService {
return
el
;
};
if
(
isWindows
)
{
if
(
!
isMacintosh
)
{
// The svgs and styles for the titlebar come from the electron-titlebar-windows package
$
(
this
.
titleContainer
).
div
({
class
:
'
window-icon
'
},
(
builder
)
=>
{
const
svg
=
$svg
(
'
svg
'
,
{
x
:
0
,
y
:
0
,
viewBox
:
'
0 0 10 1
'
});
...
...
src/vs/workbench/electron-browser/main.contribution.ts
浏览文件 @
2afb3360
...
...
@@ -378,8 +378,7 @@ configurationRegistry.registerConfiguration({
'
type
'
:
'
string
'
,
'
enum
'
:
[
'
native
'
,
'
custom
'
],
'
default
'
:
isMacintosh
?
'
custom
'
:
'
native
'
,
'
description
'
:
nls
.
localize
(
'
titleBarStyle
'
,
"
Adjust the appearance of the window title bar. Changes require a full restart to apply.
"
),
'
included
'
:
isMacintosh
||
isWindows
'
description
'
:
nls
.
localize
(
'
titleBarStyle
'
,
"
Adjust the appearance of the window title bar. Changes require a full restart to apply.
"
)
},
'
window.nativeTabs
'
:
{
'
type
'
:
'
boolean
'
,
...
...
src/vs/workbench/electron-browser/workbench.ts
浏览文件 @
2afb3360
...
...
@@ -734,9 +734,6 @@ export class Workbench implements IPartService {
}
private
getCustomTitleBarStyle
():
'
custom
'
{
if
(
!
isMacintosh
&&
!
isWindows
)
{
return
null
;
// custom title bar is only supported on Mac and Windows currently
}
const
isDev
=
!
this
.
environmentService
.
isBuilt
||
this
.
environmentService
.
isExtensionDevelopment
;
if
(
isMacintosh
&&
isDev
)
{
...
...
src/vs/workbench/test/workbenchTestServices.ts
浏览文件 @
2afb3360
...
...
@@ -1130,10 +1130,6 @@ export class TestWindowsService implements IWindowsService {
return
TPromise
.
as
(
void
0
);
}
addMaximizeListener
(
windowId
:
number
,
listener
:
(
maximized
:
boolean
)
=>
void
):
TPromise
<
void
>
{
return
TPromise
.
as
(
void
0
);
}
onWindowTitleDoubleClick
(
windowId
:
number
):
TPromise
<
void
>
{
return
TPromise
.
as
(
void
0
);
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录