Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
后端镜像
Tabby
提交
c2657568
T
Tabby
项目概览
后端镜像
/
Tabby
通知
37
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,发现更多精彩内容 >>
未验证
提交
c2657568
编写于
7月 17, 2021
作者:
E
Eugene Pankov
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
updated web demo for new profiles
上级
dbe7b8cf
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
31 addition
and
18 deletion
+31
-18
tabby-web-demo/src/components/terminalTab.component.ts
tabby-web-demo/src/components/terminalTab.component.ts
+1
-1
tabby-web-demo/src/session.ts
tabby-web-demo/src/session.ts
+30
-17
未找到文件。
tabby-web-demo/src/components/terminalTab.component.ts
浏览文件 @
c2657568
...
...
@@ -21,7 +21,7 @@ export class DemoTerminalTabComponent extends BaseTerminalTabComponent {
ngOnInit
():
void
{
this
.
logger
=
this
.
log
.
create
(
'
terminalTab
'
)
this
.
session
=
new
Session
(
this
.
logger
)
this
.
session
=
new
Session
(
this
.
injector
,
this
.
logger
)
super
.
ngOnInit
()
}
...
...
tabby-web-demo/src/session.ts
浏览文件 @
c2657568
/* eslint-disable @typescript-eslint/no-empty-function */
import
{
Injector
,
NgZone
}
from
'
@angular/core
'
import
*
as
path
from
'
path
'
import
{
BaseSession
}
from
'
tabby-terminal
'
import
{
Logger
}
from
'
../../tabby-core/typings
'
const
currentScript
:
any
=
document
.
currentScript
export
class
Session
extends
BaseSession
{
private
dataPath
=
window
[
'
tabbyWebDemoDataPath
'
]
??
currentScript
.
src
+
'
../../../data
'
private
vm
:
any
private
zone
:
NgZone
static
v86Loaded
=
false
constructor
(
injector
:
Injector
,
logger
:
Logger
,
)
{
super
(
logger
)
this
.
zone
=
injector
.
get
(
NgZone
)
}
async
start
():
Promise
<
void
>
{
this
.
open
=
true
this
.
emitMessage
(
'
Hey
\r\n
'
)
...
...
@@ -25,23 +36,25 @@ export class Session extends BaseSession {
})
}
this
.
vm
=
new
window
[
'
V86Starter
'
]({
bios
:
{
url
:
`
${
this
.
dataPath
}
/bios.bin`
,
},
vga_bios
:
{
url
:
`
${
this
.
dataPath
}
/vgabios.bin`
,
},
wasm_path
:
`
${
this
.
dataPath
}
/v86.wasm`
,
cdrom
:
{
url
:
`
${
this
.
dataPath
}
/linux.iso`
,
},
initial_state
:
{
url
:
`
${
this
.
dataPath
}
/v86state.bin`
,
},
autostart
:
true
,
disable_keyboard
:
true
,
disable_speaker
:
true
,
this
.
zone
.
runOutsideAngular
(()
=>
{
this
.
vm
=
new
window
[
'
V86Starter
'
]({
bios
:
{
url
:
`
${
this
.
dataPath
}
/bios.bin`
,
},
vga_bios
:
{
url
:
`
${
this
.
dataPath
}
/vgabios.bin`
,
},
wasm_path
:
`
${
this
.
dataPath
}
/v86.wasm`
,
cdrom
:
{
url
:
`
${
this
.
dataPath
}
/linux.iso`
,
},
initial_state
:
{
url
:
`
${
this
.
dataPath
}
/v86state.bin`
,
},
autostart
:
true
,
disable_keyboard
:
true
,
disable_speaker
:
true
,
})
})
this
.
vm
.
add_listener
(
'
emulator-ready
'
,
()
=>
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录