Update EditUsers.plugin.js

This commit is contained in:
Mirco Wittrien 2019-02-19 12:09:01 +01:00
parent 3c73958645
commit f00d0f6d3d
1 changed files with 11 additions and 2 deletions

View File

@ -3,7 +3,7 @@
class EditUsers {
getName () {return "EditUsers";}
getVersion () {return "3.2.6";}
getVersion () {return "3.2.7";}
getAuthor () {return "DevilBro";}
@ -11,7 +11,7 @@ class EditUsers {
initConstructor () {
this.changelog = {
"improved":[["Affected Elements","Names/Avatars will also now be changed in the member/invite/ban overview in the guildsettings"]]
"improved":[["Affected Elements","Avatar in the ScreenShare popout is also now changed"]]
};
this.labels = {};
@ -27,6 +27,7 @@ class EditUsers {
"MessageUsername":"componentDidMount",
"DirectMessage":"componentDidMount",
"CallAvatar":"componentDidMount",
"PictureInPictureVideo":"componentDidMount",
"PrivateChannel":["componentDidMount","componentDidUpdate"],
"HeaderBar":["componentDidMount","componentDidUpdate"],
"Clickable":"componentDidMount",
@ -584,6 +585,14 @@ class EditUsers {
}
}
processPictureInPictureVideo (instance, wrapper) {
console.log(instance);
if (instance.props && instance.props.backgroundKey) {
let user = this.UserUtils.getUser(instance.props.backgroundKey);
if (user) this.changeAvatar(user, this.getAvatarDiv(wrapper));
}
}
processPrivateChannel (instance, wrapper) {
if (instance.props && instance.props.user) {
let username = wrapper.querySelector(BDFDB.dotCN.dmchannelname);