Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
97af4fb3
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,发现更多精彩内容 >>
提交
97af4fb3
编写于
9月 24, 2020
作者:
R
rebornix
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
re #103454. notebook/comments/find remove toggle.
上级
737d2c33
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
11 addition
and
11 deletion
+11
-11
src/vs/workbench/contrib/codeEditor/browser/find/simpleFindReplaceWidget.ts
...ontrib/codeEditor/browser/find/simpleFindReplaceWidget.ts
+1
-1
src/vs/workbench/contrib/comments/browser/commentsView.ts
src/vs/workbench/contrib/comments/browser/commentsView.ts
+3
-3
src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.ts
...orkbench/contrib/notebook/browser/notebookEditorWidget.ts
+2
-2
src/vs/workbench/contrib/notebook/browser/view/output/transforms/richTransform.ts
.../notebook/browser/view/output/transforms/richTransform.ts
+2
-2
src/vs/workbench/contrib/notebook/browser/view/renderers/cellRenderer.ts
...h/contrib/notebook/browser/view/renderers/cellRenderer.ts
+2
-2
src/vs/workbench/contrib/notebook/browser/view/renderers/codeCell.ts
...bench/contrib/notebook/browser/view/renderers/codeCell.ts
+1
-1
未找到文件。
src/vs/workbench/contrib/codeEditor/browser/find/simpleFindReplaceWidget.ts
浏览文件 @
97af4fb3
...
@@ -314,7 +314,7 @@ export abstract class SimpleFindReplaceWidget extends Widget {
...
@@ -314,7 +314,7 @@ export abstract class SimpleFindReplaceWidget extends Widget {
this
.
_replaceBtn
.
setEnabled
(
this
.
_isVisible
&&
this
.
_isReplaceVisible
&&
findInputIsNonEmpty
);
this
.
_replaceBtn
.
setEnabled
(
this
.
_isVisible
&&
this
.
_isReplaceVisible
&&
findInputIsNonEmpty
);
this
.
_replaceAllBtn
.
setEnabled
(
this
.
_isVisible
&&
this
.
_isReplaceVisible
&&
findInputIsNonEmpty
);
this
.
_replaceAllBtn
.
setEnabled
(
this
.
_isVisible
&&
this
.
_isReplaceVisible
&&
findInputIsNonEmpty
);
dom
.
toggleClass
(
this
.
_domNode
,
'
replaceToggled
'
,
this
.
_isReplaceVisible
);
this
.
_domNode
.
classList
.
toggle
(
'
replaceToggled
'
,
this
.
_isReplaceVisible
);
this
.
_toggleReplaceBtn
.
setExpanded
(
this
.
_isReplaceVisible
);
this
.
_toggleReplaceBtn
.
setExpanded
(
this
.
_isReplaceVisible
);
}
}
...
...
src/vs/workbench/contrib/comments/browser/commentsView.ts
浏览文件 @
97af4fb3
...
@@ -113,7 +113,7 @@ export class CommentsPanel extends ViewPane {
...
@@ -113,7 +113,7 @@ export class CommentsPanel extends ViewPane {
}
}
private
async
renderComments
():
Promise
<
void
>
{
private
async
renderComments
():
Promise
<
void
>
{
dom
.
toggleClass
(
this
.
treeContainer
,
'
hidden
'
,
!
this
.
commentsModel
.
hasCommentThreads
());
this
.
treeContainer
.
classList
.
toggle
(
'
hidden
'
,
!
this
.
commentsModel
.
hasCommentThreads
());
await
this
.
tree
.
setInput
(
this
.
commentsModel
);
await
this
.
tree
.
setInput
(
this
.
commentsModel
);
this
.
renderMessage
();
this
.
renderMessage
();
}
}
...
@@ -144,7 +144,7 @@ export class CommentsPanel extends ViewPane {
...
@@ -144,7 +144,7 @@ export class CommentsPanel extends ViewPane {
private
renderMessage
():
void
{
private
renderMessage
():
void
{
this
.
messageBox
.
textContent
=
this
.
commentsModel
.
getMessage
();
this
.
messageBox
.
textContent
=
this
.
commentsModel
.
getMessage
();
dom
.
toggleClass
(
this
.
messageBoxContainer
,
'
hidden
'
,
this
.
commentsModel
.
hasCommentThreads
());
this
.
messageBoxContainer
.
classList
.
toggle
(
'
hidden
'
,
this
.
commentsModel
.
hasCommentThreads
());
}
}
private
createTree
():
void
{
private
createTree
():
void
{
...
@@ -237,7 +237,7 @@ export class CommentsPanel extends ViewPane {
...
@@ -237,7 +237,7 @@ export class CommentsPanel extends ViewPane {
this
.
collapseAllAction
.
enabled
=
this
.
commentsModel
.
hasCommentThreads
();
this
.
collapseAllAction
.
enabled
=
this
.
commentsModel
.
hasCommentThreads
();
}
}
dom
.
toggleClass
(
this
.
treeContainer
,
'
hidden
'
,
!
this
.
commentsModel
.
hasCommentThreads
());
this
.
treeContainer
.
classList
.
toggle
(
'
hidden
'
,
!
this
.
commentsModel
.
hasCommentThreads
());
this
.
tree
.
updateChildren
().
then
(()
=>
{
this
.
tree
.
updateChildren
().
then
(()
=>
{
this
.
renderMessage
();
this
.
renderMessage
();
},
(
e
)
=>
{
},
(
e
)
=>
{
...
...
src/vs/workbench/contrib/notebook/browser/notebookEditorWidget.ts
浏览文件 @
97af4fb3
...
@@ -861,8 +861,8 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditor
...
@@ -861,8 +861,8 @@ export class NotebookEditorWidget extends Disposable implements INotebookEditor
const
notebookMetadata
=
this
.
viewModel
!
.
metadata
;
const
notebookMetadata
=
this
.
viewModel
!
.
metadata
;
this
.
_editorEditable
?.
set
(
!!
notebookMetadata
?.
editable
);
this
.
_editorEditable
?.
set
(
!!
notebookMetadata
?.
editable
);
this
.
_editorRunnable
?.
set
(
!!
notebookMetadata
?.
runnable
);
this
.
_editorRunnable
?.
set
(
!!
notebookMetadata
?.
runnable
);
DOM
.
toggleClass
(
this
.
_overlayContainer
,
'
notebook-editor-editable
'
,
!!
notebookMetadata
?.
editable
);
this
.
_overflowContainer
.
classList
.
toggle
(
'
notebook-editor-editable
'
,
!!
notebookMetadata
?.
editable
);
DOM
.
toggleClass
(
this
.
getDomNode
(),
'
notebook-editor-editable
'
,
!!
notebookMetadata
?.
editable
);
this
.
getDomNode
().
classList
.
toggle
(
'
notebook-editor-editable
'
,
!!
notebookMetadata
?.
editable
);
this
.
_notebookExecuting
?.
set
(
notebookMetadata
.
runState
===
NotebookRunState
.
Running
);
this
.
_notebookExecuting
?.
set
(
notebookMetadata
.
runState
===
NotebookRunState
.
Running
);
}
}
...
...
src/vs/workbench/contrib/notebook/browser/view/output/transforms/richTransform.ts
浏览文件 @
97af4fb3
...
@@ -186,7 +186,7 @@ class RichRenderer implements IOutputTransformContribution {
...
@@ -186,7 +186,7 @@ class RichRenderer implements IOutputTransformContribution {
const
image
=
document
.
createElement
(
'
img
'
);
const
image
=
document
.
createElement
(
'
img
'
);
image
.
src
=
`data:image/png;base64,
${
output
.
data
[
'
image/png
'
]}
`
;
image
.
src
=
`data:image/png;base64,
${
output
.
data
[
'
image/png
'
]}
`
;
const
display
=
document
.
createElement
(
'
div
'
);
const
display
=
document
.
createElement
(
'
div
'
);
DOM
.
addClasses
(
display
,
'
display
'
);
display
.
classList
.
add
(
'
display
'
);
display
.
appendChild
(
image
);
display
.
appendChild
(
image
);
container
.
appendChild
(
display
);
container
.
appendChild
(
display
);
return
{
type
:
RenderOutputType
.
None
,
hasDynamicHeight
:
true
};
return
{
type
:
RenderOutputType
.
None
,
hasDynamicHeight
:
true
};
...
@@ -196,7 +196,7 @@ class RichRenderer implements IOutputTransformContribution {
...
@@ -196,7 +196,7 @@ class RichRenderer implements IOutputTransformContribution {
const
image
=
document
.
createElement
(
'
img
'
);
const
image
=
document
.
createElement
(
'
img
'
);
image
.
src
=
`data:image/jpeg;base64,
${
output
.
data
[
'
image/jpeg
'
]}
`
;
image
.
src
=
`data:image/jpeg;base64,
${
output
.
data
[
'
image/jpeg
'
]}
`
;
const
display
=
document
.
createElement
(
'
div
'
);
const
display
=
document
.
createElement
(
'
div
'
);
DOM
.
addClasses
(
display
,
'
display
'
);
display
.
classList
.
add
(
'
display
'
);
display
.
appendChild
(
image
);
display
.
appendChild
(
image
);
container
.
appendChild
(
display
);
container
.
appendChild
(
display
);
return
{
type
:
RenderOutputType
.
None
,
hasDynamicHeight
:
true
};
return
{
type
:
RenderOutputType
.
None
,
hasDynamicHeight
:
true
};
...
...
src/vs/workbench/contrib/notebook/browser/view/renderers/cellRenderer.ts
浏览文件 @
97af4fb3
...
@@ -785,7 +785,7 @@ export class CodeCellRenderer extends AbstractCellRenderer implements IListRende
...
@@ -785,7 +785,7 @@ export class CodeCellRenderer extends AbstractCellRenderer implements IListRende
private
updateForMetadata
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
private
updateForMetadata
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
const
metadata
=
element
.
getEvaluatedMetadata
(
this
.
notebookEditor
.
viewModel
!
.
notebookDocument
.
metadata
);
const
metadata
=
element
.
getEvaluatedMetadata
(
this
.
notebookEditor
.
viewModel
!
.
notebookDocument
.
metadata
);
DOM
.
toggleClass
(
templateData
.
container
,
'
runnable
'
,
!!
metadata
.
runnable
);
templateData
.
container
.
classList
.
toggle
(
'
runnable
'
,
!!
metadata
.
runnable
);
this
.
updateExecutionOrder
(
metadata
,
templateData
);
this
.
updateExecutionOrder
(
metadata
,
templateData
);
templateData
.
statusBar
.
cellStatusMessageContainer
.
textContent
=
metadata
?.
statusMessage
||
''
;
templateData
.
statusBar
.
cellStatusMessageContainer
.
textContent
=
metadata
?.
statusMessage
||
''
;
...
@@ -826,7 +826,7 @@ export class CodeCellRenderer extends AbstractCellRenderer implements IListRende
...
@@ -826,7 +826,7 @@ export class CodeCellRenderer extends AbstractCellRenderer implements IListRende
}
}
private
updateForHover
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
private
updateForHover
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
DOM
.
toggleClass
(
templateData
.
container
,
'
cell-output-hover
'
,
element
.
outputIsHovered
);
templateData
.
container
.
classList
.
toggle
(
'
cell-output-hover
'
,
element
.
outputIsHovered
);
}
}
private
updateForLayout
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
private
updateForLayout
(
element
:
CodeCellViewModel
,
templateData
:
CodeCellRenderTemplate
):
void
{
...
...
src/vs/workbench/contrib/notebook/browser/view/renderers/codeCell.ts
浏览文件 @
97af4fb3
...
@@ -84,7 +84,7 @@ export class CodeCell extends Disposable {
...
@@ -84,7 +84,7 @@ export class CodeCell extends Disposable {
templateData
.
editor
?.
focus
();
templateData
.
editor
?.
focus
();
}
}
DOM
.
toggleClass
(
templateData
.
container
,
'
cell-editor-focus
'
,
viewCell
.
focusMode
===
CellFocusMode
.
Editor
);
templateData
.
container
.
classList
.
toggle
(
'
cell-editor-focus
'
,
viewCell
.
focusMode
===
CellFocusMode
.
Editor
);
};
};
const
updateForCollapseState
=
()
=>
{
const
updateForCollapseState
=
()
=>
{
this
.
viewUpdate
();
this
.
viewUpdate
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录