fix(webterminal): bug fix test

pull/112/head
liuzheng712 2016-03-03 17:03:47 +08:00
parent 32519f8eae
commit a816a7b149
1 changed files with 9 additions and 3 deletions

View File

@ -55,10 +55,16 @@ WSSHClient.prototype.send = function (data) {
function openTerminal(options) {
var client = new WSSHClient();
var term = new Terminal(80, 24, function (key) {
client.send(key);
var term = new Terminal({
rows: rowHeight,
cols: colWidth,
useStyle: true,
screenKeys: true
});
term.open();
term.on('data', function (data) {
client.send(data)
});
$('.terminal').detach().appendTo('#term');
term.resize(80, 24);
term.write('Connecting...');