Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
后端镜像
Tabby
提交
edd7e9c7
T
Tabby
项目概览
后端镜像
/
Tabby
通知
31
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
Tabby
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
edd7e9c7
编写于
8月 02, 2021
作者:
E
Eugene Pankov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
set default cancel button in message boxes
上级
ab8061ab
变更
15
隐藏空白更改
内联
并排
Showing
15 changed file
with
43 addition
and
26 deletion
+43
-26
tabby-core/src/api/platform.ts
tabby-core/src/api/platform.ts
+1
-0
tabby-core/src/components/transfersMenu.component.ts
tabby-core/src/components/transfersMenu.component.ts
+1
-0
tabby-core/src/services/config.service.ts
tabby-core/src/services/config.service.ts
+1
-0
tabby-electron/src/services/updater.service.ts
tabby-electron/src/services/updater.service.ts
+4
-3
tabby-local/src/components/terminalTab.component.ts
tabby-local/src/components/terminalTab.component.ts
+4
-3
tabby-settings/src/components/configSyncSettingsTab.component.ts
...ettings/src/components/configSyncSettingsTab.component.ts
+2
-0
tabby-settings/src/components/profilesSettingsTab.component.ts
...-settings/src/components/profilesSettingsTab.component.ts
+9
-6
tabby-settings/src/components/vaultSettingsTab.component.ts
tabby-settings/src/components/vaultSettingsTab.component.ts
+3
-2
tabby-ssh/src/components/sshTab.component.ts
tabby-ssh/src/components/sshTab.component.ts
+4
-3
tabby-ssh/src/sftpContextMenu.ts
tabby-ssh/src/sftpContextMenu.ts
+1
-0
tabby-telnet/src/components/telnetTab.component.ts
tabby-telnet/src/components/telnetTab.component.ts
+4
-3
tabby-terminal/src/api/baseTerminalTab.component.ts
tabby-terminal/src/api/baseTerminalTab.component.ts
+1
-0
tabby-terminal/src/components/colorSchemeSettingsTab.component.ts
...rminal/src/components/colorSchemeSettingsTab.component.ts
+3
-2
tabby-terminal/src/components/loginScriptsSettings.component.ts
...terminal/src/components/loginScriptsSettings.component.ts
+4
-3
tabby-web/src/platform.ts
tabby-web/src/platform.ts
+1
-1
未找到文件。
tabby-core/src/api/platform.ts
浏览文件 @
edd7e9c7
...
...
@@ -13,6 +13,7 @@ export interface MessageBoxOptions {
detail
?:
string
buttons
:
string
[]
defaultId
?:
number
cancelId
?:
number
}
export
interface
MessageBoxResult
{
...
...
tabby-core/src/components/transfersMenu.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -43,6 +43,7 @@ export class TransfersMenuComponent {
message
:
'
There are active file transfers
'
,
buttons
:
[
'
Abort all
'
,
'
Do not abort
'
],
defaultId
:
1
,
cancelId
:
1
,
})).
response
===
1
)
{
return
}
...
...
tabby-core/src/services/config.service.ts
浏览文件 @
edd7e9c7
...
...
@@ -375,6 +375,7 @@ export class ConfigService {
detail
:
e
.
toString
(),
buttons
:
[
'
Erase config
'
,
'
Quit
'
],
defaultId
:
1
,
cancelId
:
1
,
})
if
(
result
.
response
===
1
)
{
this
.
platform
.
quit
()
...
...
tabby-electron/src/services/updater.service.ts
浏览文件 @
edd7e9c7
...
...
@@ -126,10 +126,11 @@ export class ElectronUpdaterService extends UpdaterService {
{
type
:
'
warning
'
,
message
:
'
Installing the update will close all tabs and restart Tabby.
'
,
buttons
:
[
'
Cancel
'
,
'
Update
'
],
defaultId
:
1
,
buttons
:
[
'
Update
'
,
'
Cancel
'
],
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
await
this
.
downloaded
this
.
electron
.
autoUpdater
.
quitAndInstall
()
}
...
...
tabby-local/src/components/terminalTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -106,10 +106,11 @@ export class TerminalTabComponent extends BaseTerminalTabComponent {
{
type
:
'
warning
'
,
message
:
`"
${
children
[
0
].
command
}
" is still running. Close?`
,
buttons
:
[
'
Cancel
'
,
'
Kill
'
],
defaultId
:
1
,
buttons
:
[
'
Kill
'
,
'
Cancel
'
],
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
===
1
)).
response
===
0
}
ngOnDestroy
():
void
{
...
...
tabby-settings/src/components/configSyncSettingsTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -73,6 +73,7 @@ export class ConfigSyncSettingsTabComponent extends BaseComponent {
message
:
'
Overwrite the config on the remote side and start syncing?
'
,
buttons
:
[
'
Overwrite remote and sync
'
,
'
Cancel
'
],
defaultId
:
1
,
cancelId
:
1
,
})).
response
===
1
)
{
return
}
...
...
@@ -89,6 +90,7 @@ export class ConfigSyncSettingsTabComponent extends BaseComponent {
message
:
'
Overwrite the local config and start syncing?
'
,
buttons
:
[
'
Overwrite local and sync
'
,
'
Cancel
'
],
defaultId
:
1
,
cancelId
:
1
,
})).
response
===
1
)
{
return
}
...
...
tabby-settings/src/components/profilesSettingsTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -106,10 +106,11 @@ export class ProfilesSettingsTabComponent extends BaseComponent {
{
type
:
'
warning
'
,
message
:
`Delete "
${
profile
.
name
}
"?`
,
buttons
:
[
'
Keep
'
,
'
Delete
'
],
defaultId
:
0
,
buttons
:
[
'
Delete
'
,
'
Keep
'
],
defaultId
:
1
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
this
.
profilesService
.
providerForProfile
(
profile
)?.
deleteProfile
(
this
.
profilesService
.
getConfigProxyForProfile
(
profile
))
this
.
config
.
store
.
profiles
=
this
.
config
.
store
.
profiles
.
filter
(
x
=>
x
!==
profile
)
...
...
@@ -164,16 +165,18 @@ export class ProfilesSettingsTabComponent extends BaseComponent {
{
type
:
'
warning
'
,
message
:
`Delete "
${
group
.
name
}
"?`
,
buttons
:
[
'
Keep
'
,
'
Delete
'
],
defaultId
:
0
,
buttons
:
[
'
Delete
'
,
'
Keep
'
],
defaultId
:
1
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
if
((
await
this
.
platform
.
showMessageBox
(
{
type
:
'
warning
'
,
message
:
`Delete the group's profiles?`
,
buttons
:
[
'
Move to "Ungrouped"
'
,
'
Delete
'
],
defaultId
:
0
,
cancelId
:
0
,
}
)).
response
===
0
)
{
for
(
const
profile
of
this
.
profiles
.
filter
(
x
=>
x
.
group
===
group
.
name
))
{
...
...
tabby-settings/src/components/vaultSettingsTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -42,10 +42,11 @@ export class VaultSettingsTabComponent extends BaseComponent {
{
type
:
'
warning
'
,
message
:
'
Delete vault contents?
'
,
buttons
:
[
'
Keep
'
,
'
Delete
'
],
buttons
:
[
'
Delete
'
,
'
Keep
'
],
defaultId
:
1
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
await
this
.
vault
.
setEnabled
(
false
)
}
}
...
...
tabby-ssh/src/components/sshTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -209,10 +209,11 @@ export class SSHTabComponent extends BaseTerminalTabComponent {
{
type
:
'
warning
'
,
message
:
`Disconnect from
${
this
.
profile
?.
options
.
host
}
?`
,
buttons
:
[
'
Cancel
'
,
'
Disconnect
'
],
defaultId
:
1
,
buttons
:
[
'
Disconnect
'
,
'
Do not close
'
],
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
===
1
)).
response
===
0
}
async
openSFTP
():
Promise
<
void
>
{
...
...
tabby-ssh/src/sftpContextMenu.ts
浏览文件 @
edd7e9c7
...
...
@@ -27,6 +27,7 @@ export class CommonSFTPContextMenu extends SFTPContextMenuItemProvider {
type
:
'
warning
'
,
message
:
`Delete
${
item
.
fullPath
}
?`
,
defaultId
:
0
,
cancelId
:
1
,
buttons
:
[
'
Delete
'
,
'
Cancel
'
],
})).
response
===
0
)
{
await
this
.
deleteItem
(
item
,
panel
.
sftp
)
...
...
tabby-telnet/src/components/telnetTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -119,9 +119,10 @@ export class TelnetTabComponent extends BaseTerminalTabComponent {
{
type
:
'
warning
'
,
message
:
`Disconnect from
${
this
.
profile
?.
options
.
host
}
?`
,
buttons
:
[
'
Cancel
'
,
'
Disconnect
'
],
defaultId
:
1
,
buttons
:
[
'
Disconnect
'
,
'
Do not close
'
],
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
===
1
)).
response
===
0
}
}
tabby-terminal/src/api/baseTerminalTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -445,6 +445,7 @@ export class BaseTerminalTabComponent extends BaseTabComponent implements OnInit
message
:
`Paste multiple lines?`
,
buttons
,
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
if
(
result
===
1
)
{
...
...
tabby-terminal/src/components/colorSchemeSettingsTab.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -79,10 +79,11 @@ export class ColorSchemeSettingsTabComponent {
{
type
:
'
warning
'
,
message
:
`Delete "
${
scheme
.
name
}
"?`
,
buttons
:
[
'
Keep
'
,
'
Delete
'
],
buttons
:
[
'
Delete
'
,
'
Keep
'
],
defaultId
:
1
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
this
.
customColorSchemes
=
this
.
customColorSchemes
.
filter
(
x
=>
x
.
name
!==
scheme
.
name
)
this
.
config
.
store
.
terminal
.
customColorSchemes
=
this
.
customColorSchemes
this
.
config
.
save
()
...
...
tabby-terminal/src/components/loginScriptsSettings.component.ts
浏览文件 @
edd7e9c7
...
...
@@ -27,10 +27,11 @@ export class LoginScriptsSettingsComponent {
type
:
'
warning
'
,
message
:
'
Delete this script?
'
,
detail
:
script
.
expect
,
buttons
:
[
'
Keep
'
,
'
Delete
'
],
defaultId
:
1
,
buttons
:
[
'
Delete
'
,
'
Keep
'
],
defaultId
:
0
,
cancelId
:
1
,
}
)).
response
===
1
)
{
)).
response
===
0
)
{
this
.
scripts
=
this
.
scripts
.
filter
(
x
=>
x
!==
script
)
}
}
...
...
tabby-web/src/platform.ts
浏览文件 @
edd7e9c7
...
...
@@ -100,7 +100,7 @@ export class WebPlatformService extends PlatformService {
const
response
=
await
modal
.
result
return
{
response
}
}
catch
{
return
{
response
:
0
}
return
{
response
:
options
.
cancelId
??
1
}
}
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录