replace contacts with contacts2

This commit is contained in:
ansuz
2017-08-25 16:07:53 +02:00
parent 57d0c6c973
commit 54eefd3d94
7 changed files with 10 additions and 138 deletions

View File

@@ -4,9 +4,12 @@ define([
'/common/toolbar2.js',
'/common/cryptpad-common.js',
'/common/common-messenger.js',
'/contacts/messenger-ui.js',
'css!/bower_components/components-font-awesome/css/font-awesome.min.css',
'less!/customize/src/less/cryptpad.less',
], function ($, Crypto, Toolbar, Cryptpad) {
], function ($, Crypto, Toolbar, Cryptpad, Messenger, UI) {
var Messages = Cryptpad.Messages;
var APP = window.APP = {
@@ -46,14 +49,11 @@ define([
console.error('reconnecting: ', uid);
Cryptpad.findOKButton().click();
APP.messenger.cleanFriendChannels();
APP.messenger.openFriendChannels();
APP.messenger.setEditable(true);
//APP.messenger.cleanFriendChannels();
//APP.messenger.openFriendChannels();
//APP.messenger.setEditable(true);
});
var ui = APP.ui = Cryptpad.initMessagingUI(Cryptpad, $list, $messages);
APP.messenger = Cryptpad.initMessaging(Cryptpad, ui);
var $infoBlock = $('<div>', {'class': 'info'}).appendTo($messages);
$('<h2>').text(Messages.contacts_info1).appendTo($infoBlock);
var $ul = $('<ul>').appendTo($infoBlock);
@@ -61,7 +61,8 @@ define([
$('<li>').text(Messages.contacts_info3).appendTo($ul);
//$('<li>').text(Messages.contacts_info4).appendTo($ul);
Cryptpad.removeLoadingScreen();
var messenger = window.messenger = Messenger.messenger(Cryptpad);
UI.create(messenger, $list, $messages);
};
Cryptpad.ready(function () {