mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 10:37:34 +00:00
Finished nc (notification center topic style refactoring) - fixes #60
This commit is contained in:
parent
cacd5d74c0
commit
76d9450257
9 changed files with 67 additions and 30 deletions
|
|
@ -37,7 +37,15 @@ function (Nc, Channel) {
|
|||
};
|
||||
|
||||
PipeToServer.prototype.onMessage = function (message) {
|
||||
Nc.trigger(Nc.ns.channel.events.controlCommand + recipient, message);
|
||||
switch(message.recipient) {
|
||||
case 'channel':
|
||||
Nc.trigger(Nc.ns.channel.events.controlCommand.channel, message);
|
||||
break;
|
||||
default:
|
||||
Nc.trigger(Nc.ns.channel.events.controlCommand.user + message.recipient, message);
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
PipeToServer.prototype.destroy = function() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue