Rename the closured converse object to _converse
to indicate that it's private and to differentiate it from the outer "global" converse object.
This commit is contained in:
parent
a30cf931b8
commit
0424df9edc
@ -756,6 +756,12 @@
|
||||
}));
|
||||
});
|
||||
|
||||
describe("when sent by the current user", function () {
|
||||
it("will always cause the chat area to be scrolled down", mock.initConverse(function (_converse) {
|
||||
// TODO
|
||||
}));
|
||||
});
|
||||
|
||||
it("is ignored if it's a malformed headline message", mock.initConverse(function (_converse) {
|
||||
test_utils.createContacts(_converse, 'current');
|
||||
test_utils.openControlBox();
|
||||
|
@ -3,6 +3,7 @@
|
||||
define([
|
||||
"converse_api",
|
||||
"mock",
|
||||
"converse_api",
|
||||
"test_utils",
|
||||
"utils",
|
||||
"transcripts"
|
||||
|
@ -32,6 +32,7 @@
|
||||
$msg = converse.env.$msg,
|
||||
_ = converse.env._,
|
||||
moment = converse.env.moment;
|
||||
|
||||
var KEY = {
|
||||
ENTER: 13,
|
||||
FORWARD_SLASH: 47
|
||||
|
@ -44,7 +44,6 @@
|
||||
"use strict";
|
||||
|
||||
var USERS_PANEL_ID = 'users';
|
||||
|
||||
// Strophe methods for building stanzas
|
||||
var Strophe = converse.env.Strophe,
|
||||
utils = converse.env.utils;
|
||||
|
@ -394,7 +394,6 @@
|
||||
_converse._tearDown();
|
||||
_converse.chatboxviews.closeAllChatBoxes();
|
||||
_converse.emit('disconnected');
|
||||
return 'disconnected';
|
||||
};
|
||||
|
||||
this.onDisconnected = function () {
|
||||
|
@ -311,7 +311,6 @@
|
||||
* loaded by converse.js's plugin machinery.
|
||||
*/
|
||||
var _converse = this._converse;
|
||||
|
||||
// Add new HTML template
|
||||
_converse.templates.dragresize = tpl_dragresize;
|
||||
|
||||
|
@ -22,13 +22,13 @@
|
||||
*/
|
||||
var from_jid = message.getAttribute('from');
|
||||
if (utils.isHeadlineMessage(message)) {
|
||||
converse.chatboxes.create({
|
||||
_converse.chatboxes.create({
|
||||
'id': from_jid,
|
||||
'jid': from_jid,
|
||||
'fullname': from_jid,
|
||||
'type': 'headline'
|
||||
}).createMessage(message, undefined, message);
|
||||
converse.emit('message', message);
|
||||
_converse.emit('message', message);
|
||||
}
|
||||
return true;
|
||||
};
|
||||
|
@ -31,7 +31,6 @@
|
||||
moment = converse.env.moment;
|
||||
|
||||
converse.plugins.add('converse-minimize', {
|
||||
|
||||
overrides: {
|
||||
// Overrides mentioned here will be picked up by converse.js's
|
||||
// plugin architecture they will replace existing methods on the
|
||||
|
@ -31,7 +31,6 @@
|
||||
"converse-chatview"
|
||||
], factory);
|
||||
}(this, function (
|
||||
_converse,
|
||||
converse,
|
||||
tpl_chatarea,
|
||||
tpl_chatroom,
|
||||
|
@ -22,7 +22,6 @@
|
||||
* loaded by converse.js's plugin machinery.
|
||||
*/
|
||||
var _converse = this._converse;
|
||||
|
||||
// For translations
|
||||
var __ = _converse.__;
|
||||
var ___ = _converse.___;
|
||||
|
@ -28,6 +28,7 @@
|
||||
var HAS_CSPRNG = ((!_.isUndefined(crypto)) &&
|
||||
((_.isFunction(crypto.randomBytes)) || (_.isFunction(crypto.getRandomValues))
|
||||
));
|
||||
|
||||
var HAS_CRYPTO = HAS_CSPRNG && (
|
||||
(!_.isUndefined(CryptoJS)) &&
|
||||
(!_.isUndefined(otr.OTR)) &&
|
||||
|
Loading…
Reference in New Issue
Block a user