Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
04bfb983
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,体验更适合开发者的 AI 搜索 >>
提交
04bfb983
编写于
9月 20, 2019
作者:
J
Joao Moreno
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
scm tree: proper icon theme alignment
上级
3a7ac688
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
27 addition
and
4 deletion
+27
-4
src/vs/workbench/browser/parts/views/media/views.css
src/vs/workbench/browser/parts/views/media/views.css
+3
-3
src/vs/workbench/contrib/scm/browser/media/scmViewlet.css
src/vs/workbench/contrib/scm/browser/media/scmViewlet.css
+6
-0
src/vs/workbench/contrib/scm/browser/repositoryPanel.ts
src/vs/workbench/contrib/scm/browser/repositoryPanel.ts
+18
-1
未找到文件。
src/vs/workbench/browser/parts/views/media/views.css
浏览文件 @
04bfb983
...
...
@@ -52,9 +52,9 @@
/* File icons in trees */
.file-icon-themable-tree.align-icons-and-twisties
.monaco-tl-twistie
:not
(
.collapsible
),
.file-icon-themable-tree
.align-icon-with-twisty
.monaco-tl-twistie
:not
(
.collapsible
),
.file-icon-themable-tree.hide-arrows
.monaco-tl-twistie
{
.file-icon-themable-tree.align-icons-and-twisties
.monaco-tl-twistie
:not
(
.
force-twistie
)
:not
(
.
collapsible
),
.file-icon-themable-tree
.align-icon-with-twisty
.monaco-tl-twistie
:not
(
.
force-twistie
)
:not
(
.
collapsible
),
.file-icon-themable-tree.hide-arrows
.monaco-tl-twistie
:not
(
.force-twistie
)
{
background-image
:
none
!important
;
width
:
0
!important
;
margin-right
:
0
!important
;
...
...
src/vs/workbench/contrib/scm/browser/media/scmViewlet.css
浏览文件 @
04bfb983
...
...
@@ -192,3 +192,9 @@
.scm-viewlet
.scm-editor.scroll
>
.monaco-inputbox
>
.wrapper
>
textarea
.input
{
overflow-y
:
scroll
;
}
.scm-viewlet
.list-view-mode
.monaco-tl-twistie
:not
(
.force-twistie
)
:not
(
.collapsible
)
{
background-image
:
none
!important
;
width
:
8px
!important
;
margin-right
:
0
!important
;
}
src/vs/workbench/contrib/scm/browser/repositoryPanel.ts
浏览文件 @
04bfb983
...
...
@@ -49,6 +49,7 @@ import { IViewDescriptor } from 'vs/workbench/common/views';
import
{
localize
}
from
'
vs/nls
'
;
import
{
flatten
}
from
'
vs/base/common/arrays
'
;
import
{
memoize
}
from
'
vs/base/common/decorators
'
;
import
{
IWorkbenchThemeService
,
IFileIconTheme
}
from
'
vs/workbench/services/themes/common/workbenchThemeService
'
;
type
TreeElement
=
ISCMResourceGroup
|
IBranchNode
<
ISCMResource
,
ISCMResourceGroup
>
|
ISCMResource
;
...
...
@@ -72,6 +73,9 @@ class ResourceGroupRenderer implements ICompressibleTreeRenderer<ISCMResourceGro
)
{
}
renderTemplate
(
container
:
HTMLElement
):
ResourceGroupTemplate
{
// hack
addClass
(
container
.
parentElement
!
.
parentElement
!
.
querySelector
(
'
.monaco-tl-twistie
'
)
!
as
HTMLElement
,
'
force-twistie
'
);
const
element
=
append
(
container
,
$
(
'
.resource-group
'
));
const
name
=
append
(
element
,
$
(
'
.name
'
));
const
actionsContainer
=
append
(
element
,
$
(
'
.actions
'
));
...
...
@@ -527,7 +531,7 @@ export class RepositoryPanel extends ViewletPanel {
readonly
repository
:
ISCMRepository
,
options
:
IViewletPanelOptions
,
@
IKeybindingService
protected
keybindingService
:
IKeybindingService
,
@
I
ThemeService
protected
themeService
:
I
ThemeService
,
@
I
WorkbenchThemeService
protected
themeService
:
IWorkbench
ThemeService
,
@
IContextMenuService
protected
contextMenuService
:
IContextMenuService
,
@
IContextViewService
protected
contextViewService
:
IContextViewService
,
@
ICommandService
protected
commandService
:
ICommandService
,
...
...
@@ -686,6 +690,19 @@ export class RepositoryPanel extends ViewletPanel {
this
.
viewModel
=
new
ViewModel
(
this
.
repository
.
provider
.
groups
,
this
.
tree
);
this
.
_register
(
this
.
viewModel
);
addClass
(
this
.
listContainer
,
'
file-icon-themable-tree
'
);
addClass
(
this
.
listContainer
,
'
show-file-icons
'
);
const
updateIndentStyles
=
(
theme
:
IFileIconTheme
)
=>
{
toggleClass
(
this
.
listContainer
,
'
list-view-mode
'
,
this
.
viewModel
.
mode
===
ViewModelMode
.
List
);
toggleClass
(
this
.
listContainer
,
'
align-icons-and-twisties
'
,
this
.
viewModel
.
mode
===
ViewModelMode
.
Tree
&&
theme
.
hasFileIcons
&&
!
theme
.
hasFolderIcons
);
toggleClass
(
this
.
listContainer
,
'
hide-arrows
'
,
this
.
viewModel
.
mode
===
ViewModelMode
.
Tree
&&
theme
.
hidesExplorerArrows
===
true
);
};
updateIndentStyles
(
this
.
themeService
.
getFileIconTheme
());
this
.
_register
(
this
.
themeService
.
onDidFileIconThemeChange
(
updateIndentStyles
));
this
.
_register
(
this
.
viewModel
.
onDidChangeMode
(()
=>
updateIndentStyles
(
this
.
themeService
.
getFileIconTheme
())));
this
.
toggleViewModelModeAction
=
new
ToggleViewModeAction
(
this
.
viewModel
);
this
.
_register
(
this
.
toggleViewModelModeAction
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录