Plugin socket events, textarea margin

This commit is contained in:
Jiiks 2016-01-07 08:44:14 +02:00
parent 98bb5a3c79
commit b51f1caf36
4 changed files with 89 additions and 4 deletions

File diff suppressed because one or more lines are too long

2
css/main.min.css vendored

File diff suppressed because one or more lines are too long

View File

@ -1443,7 +1443,12 @@ PluginModule.prototype.channelSwitch = function() {
};
PluginModule.prototype.socketEvent = function(e, data) {
$.each(bdplugins, function() {
if(!pluginCookie[this.plugin.getName()]) return;
if(typeof this.plugin.socketEvent === "function") {
this.plugin.socketEvent(data);
}
});
};
@ -1693,10 +1698,15 @@ BdApi.getUserNameById = function(id) {
return null;
};
//Set current game
//game = game
BdApi.setPlaying = function(game) {
bdws.send({"op":3,"d":{"idle_since":null,"game":{"name": game}}});
};
//Set current status
//idle_since = date
//status = status
BdApi.setStatus = function(idle_since, status) {
bdws.send({"op":3,"d":{"idle_since":idle_since,"game":{"name": status}}});
};

75
js/main.min.js vendored

File diff suppressed because one or more lines are too long