}\r
});\r
\r
+ gw.on('onaway', function (event) {\r
+ $.each(that.panels.models, function (index, panel) {\r
+ if (!panel.isChannel()) return;\r
+\r
+ member = panel.get('members').getByNick(event.nick);\r
+ if (member) {\r
+ member.set('away', !(!event.trailing));\r
+ }\r
+ });\r
+ });
+\r
\r
gw.on('onlist_start', function (data) {\r
if (kiwi.app.channel_list) {\r
// i.e. - for disable, ~ for requires ACK, = for sticky
var capabilities = command.trailing.replace(/[\-~=]/, '').split(' ');
var request;
- var want = ['multi-prefix'];
+ var want = ['multi-prefix', 'away-notify'];
if (this.irc_connection.password) {
want.push('sasl');
this.irc_connection.register();
}
},
+ 'AWAY': function (command) {
+ this.client.sendIrcCommand('away', {server: this.con_num, nick: command.nick, msg: command.trailing});
+ },
'RPL_SASLAUTHENTICATED':function (command) {
this.irc_connection.write('CAP END');
this.irc_connection.cap_negotation = false;