Cleaned up code.

This commit is contained in:
Alexander Kastius
2016-08-12 13:22:52 +02:00
parent 842a38c13a
commit fbb1cfb67b
6 changed files with 63 additions and 91 deletions

View File

@@ -6,13 +6,13 @@ CodeOceanEditorWebsocket = {
this.websocket = new WebSocket('<%= DockerClient.config['ws_client_protocol'] %>' + window.location.hostname + ':' + window.location.port + url);
this.websocket.onopen = function (evt) {
this.resetOutputTab();
}; // todo show some kind of indicator for established connection
}.bind(this); // todo show some kind of indicator for established connection
this.websocket.onclose = function (evt) { /* expected at some point */
};
}.bind(this);
this.websocket.onmessage = onmessageFunction;
this.websocket.onerror = function (evt) {
this.showWebsocketError();
};
}.bind(this);
this.websocket.flush = function () {
this.send('\n');
}