Browse Source

Updated main.js

pull/58/head
Sheng 6 years ago
parent
commit
d74c097471
  1. 6
      webssh/static/js/main.js

6
webssh/static/js/main.js

@ -202,7 +202,7 @@ jQuery(function($){
sock = new window.WebSocket(url), sock = new window.WebSocket(url),
encoding = 'utf-8', encoding = 'utf-8',
decoder = window.TextDecoder ? new window.TextDecoder(encoding) : encoding, decoder = window.TextDecoder ? new window.TextDecoder(encoding) : encoding,
terminal = document.getElementById('#terminal'), terminal = document.getElementById('terminal'),
term = new window.Terminal({ term = new window.Terminal({
cursorBlink: true, cursorBlink: true,
}); });
@ -329,7 +329,7 @@ jQuery(function($){
}); });
sock.onopen = function() { sock.onopen = function() {
$('.container').hide(); // $('.container').hide();
term.open(terminal, true); term.open(terminal, true);
term.toggleFullscreen(true); term.toggleFullscreen(true);
state = CONNECTED; state = CONNECTED;
@ -350,7 +350,7 @@ jQuery(function($){
term = undefined; term = undefined;
sock = undefined; sock = undefined;
reset_wssh(); reset_wssh();
$('.container').show(); // $('.container').show();
status.text(e.reason); status.text(e.reason);
state = DISCONNECTED; state = DISCONNECTED;
title_text = 'WebSSH'; title_text = 'WebSSH';

Loading…
Cancel
Save