FS-7312 #resolve #comment added feature NEEDS_DOC

This commit is contained in:
Anthony Minessale
2015-02-21 12:11:24 -06:00
parent 0a8cc1840b
commit 61e250a49b
3 changed files with 27 additions and 3 deletions

View File

@@ -71,6 +71,7 @@
login : null, /// auth login
passwd : null, /// auth passwd
sessid : null,
loginParams : null,
getSocket : function(onmessage_cb) { return self._getSocket(onmessage_cb); }
}, options);
@@ -250,15 +251,18 @@
};
$.JsonRpcClient.prototype.closeSocket = function() {
var self = this;
if (self.socketReady()) {
this._ws_socket.onclose = function (w) {console.log("Closing Socket");};
this._ws_socket.close();
self._ws_socket.onclose = function (w) {console.log("Closing Socket");};
self._ws_socket.close();
}
};
$.JsonRpcClient.prototype.loginData = function(params) {
var self = this;
self.options.login = params.login;
self.options.passwd = params.passwd;
self.options.loginParams = params.loginParams;
};
$.JsonRpcClient.prototype.connectSocket = function(onmessage_cb) {
@@ -418,7 +422,7 @@
if (!self.authing && response.error.code == -32000 && self.options.login && self.options.passwd) {
self.authing = true;
this.call("login", { login: self.options.login, passwd: self.options.passwd},
this.call("login", { login: self.options.login, passwd: self.options.passwd, loginParams: self.options.loginParams},
this._ws_callbacks[response.id].request_obj.method == "login" ?
function(e) {
self.authing = false;

View File

@@ -73,6 +73,7 @@
tag: null,
videoParams: {},
audioParams: {},
loginParams: {},
iceServers: false,
ringSleep: 6000
}, options);
@@ -90,6 +91,7 @@
login: verto.options.login,
passwd: verto.options.passwd,
socketUrl: verto.options.socketUrl,
loginParams: verto.options.loginParams,
sessid: verto.sessid,
onmessage: function(e) {
return verto.handleMessage(e.eventData);