Show users editing and lag, properly send message to indicate that all users have left channel and show basic error box if disconnected.

This commit is contained in:
Caleb James DeLisle
2014-11-03 16:07:39 +01:00
parent 5ae599fa07
commit 6cbdcdec65
8 changed files with 191 additions and 58 deletions

View File

@@ -933,6 +933,11 @@ var handleMessage = ChainPad.handleMessage = function (realtime, msgStr) {
}
if (msg.messageType === Message.DISCONNECT) {
if (msg.userName === '') {
realtime.userList = [];
userListChange(realtime);
return;
}
var idx = realtime.userList.indexOf(msg.userName);
if (Common.PARANOIA) { Common.assert(idx > -1); }
if (idx > -1) {