controlbox.on('unknown_command', unknownCommand);\r
\r
controlbox.on('command', allCommands);\r
- controlbox.on('command_msg', msgCommand);\r
+ controlbox.on('command:msg', msgCommand);\r
\r
- controlbox.on('command_action', actionCommand);\r
+ controlbox.on('command:action', actionCommand);\r
\r
- controlbox.on('command_join', joinCommand);\r
+ controlbox.on('command:join', joinCommand);\r
\r
- controlbox.on('command_part', partCommand);\r
+ controlbox.on('command:part', partCommand);\r
\r
- controlbox.on('command_nick', function (ev) {\r
+ controlbox.on('command:nick', function (ev) {\r
_kiwi.gateway.changeNick(ev.params[0]);\r
});\r
\r
- controlbox.on('command_query', queryCommand);\r
+ controlbox.on('command:query', queryCommand);\r
\r
- controlbox.on('command_topic', topicCommand);\r
+ controlbox.on('command:topic', topicCommand);\r
\r
- controlbox.on('command_notice', noticeCommand);\r
+ controlbox.on('command:notice', noticeCommand);\r
\r
- controlbox.on('command_quote', quoteCommand);\r
+ controlbox.on('command:quote', quoteCommand);\r
\r
- controlbox.on('command_kick', kickCommand);\r
+ controlbox.on('command:kick', kickCommand);\r
\r
- controlbox.on('command_clear', clearCommand);\r
+ controlbox.on('command:clear', clearCommand);\r
\r
\r
- controlbox.on('command_css', function (ev) {\r
+ controlbox.on('command:css', function (ev) {\r
var queryString = '?reload=' + new Date().getTime();\r
$('link[rel="stylesheet"]').each(function () {\r
this.href = this.href.replace(/\?.*|$/, queryString);\r
});\r
});\r
\r
- controlbox.on('command_js', function (ev) {\r
+ controlbox.on('command:js', function (ev) {\r
if (!ev.params[0]) return;\r
$script(ev.params[0] + '?' + (new Date().getTime()));\r
});\r
\r
\r
- controlbox.on('command_set', function (ev) {\r
+ controlbox.on('command:set', function (ev) {\r
if (!ev.params[0]) return;\r
\r
var setting = ev.params[0],\r
});\r
\r
\r
- controlbox.on('command_save', function (ev) {\r
+ controlbox.on('command:save', function (ev) {\r
_kiwi.global.settings.save();\r
_kiwi.app.panels.active.addMsg('', 'Settings have been saved');\r
});\r
\r
\r
- controlbox.on('command_alias', function (ev) {\r
+ controlbox.on('command:alias', function (ev) {\r
var name, rule;\r
\r
// No parameters passed so list them\r
controlbox.preprocessor.aliases[name] = rule;\r
});\r
\r
- controlbox.on('command_applet', appletCommand);\r
- controlbox.on('command_settings', settingsCommand);\r
+ controlbox.on('command:applet', appletCommand);\r
+ controlbox.on('command:settings', settingsCommand);\r
};\r
\r
// A fallback action. Send a raw command to the server\r
\r
// Trigger the command events\r
this.trigger('command', {command: command, params: params});\r
- this.trigger('command_' + command, {command: command, params: params});\r
+ this.trigger('command:' + command, {command: command, params: params});\r
\r
// If we didn't have any listeners for this event, fire a special case\r
// TODO: This feels dirty. Should this really be done..?\r
- if (!this._callbacks['command_' + command]) {\r
+ if (!this._callbacks['command:' + command]) {\r
this.trigger('unknown_command', {command: command, params: params});\r
}\r
}\r