update minor editors to use new realtime-input api

This commit is contained in:
ansuz
2016-03-07 11:52:18 +01:00
parent 9b228eea6b
commit 1c54af69a1
6 changed files with 68 additions and 53 deletions

View File

@@ -47,16 +47,20 @@ define([
.on('change', draw);
var rts = $('textarea').toArray().map(function (e, i) {
var rt = Realtime.start(e, // window
Config.websocketURL, // websocketUrl
userName, // userName
key.channel, // channel
key.cryptKey, // cryptKey
{
onRemote: draw,
onInit: draw,
onReady: draw
});
var config = {
onRemote: draw,
onInit: draw,
onReady: draw,
textarea: e,
websocketURL: Config.websocketURL,
userName: userName,
channel: key.channel,
cryptKey: key.cryptKey
};
var rt = Realtime.start(config);
return rt;
});
});