Some icon ids fix
parent
879f32e655
commit
9a4ec00b12
|
@ -685,6 +685,11 @@ class ChannelEntry {
|
|||
let order = this.channelTree.findChannel(this.properties.channel_order);
|
||||
this.channelTree.moveChannel(this, order, this.parent);
|
||||
} else if(key == "channel_icon_id") {
|
||||
/* For more detail lookup client::updateVariables and client_icon_id!
|
||||
* ATTENTION: This is required!
|
||||
*/
|
||||
this.properties.channel_icon_id = variable.value as any >>> 0;
|
||||
|
||||
let tag = this.channelTag().find(".icons .channel_icon");
|
||||
(this.properties.channel_icon_id > 0 ? $.fn.show : $.fn.hide).apply(tag);
|
||||
if(this.properties.channel_icon_id > 0) {
|
||||
|
|
|
@ -632,8 +632,14 @@ class ClientEntry {
|
|||
reorder_channel = true;
|
||||
update_icon_status = true;
|
||||
}
|
||||
if(variable.key == "client_icon_id")
|
||||
if(variable.key == "client_icon_id") {
|
||||
/* yeah we like javascript. Due to JS wiered integer behaviour parsing for example fails for 18446744073409829863.
|
||||
* parseInt("18446744073409829863") evaluates to 18446744073409829000.
|
||||
* In opposite "18446744073409829863" >>> 0 evaluates to 3995244544, which is the icon id :)
|
||||
*/
|
||||
this.properties.client_icon_id = variable.value as any >>> 0;
|
||||
this.updateClientIcon();
|
||||
}
|
||||
if(variable.key =="client_channel_group_id" || variable.key == "client_servergroups")
|
||||
this.update_displayed_client_groups();
|
||||
}
|
||||
|
|
|
@ -213,6 +213,11 @@ class ServerEntry {
|
|||
this.channelTree.client.tag_connection_handler.find(".server-name").text(variable.value);
|
||||
server_connections.update_ui();
|
||||
} else if(variable.key == "virtualserver_icon_id") {
|
||||
/* For more detail lookup client::updateVariables and client_icon_id!
|
||||
* ATTENTION: This is required!
|
||||
*/
|
||||
this.properties.virtualserver_icon_id = variable.value as any >>> 0;
|
||||
|
||||
if(this.channelTree.client.fileManager && this.channelTree.client.fileManager.icons)
|
||||
this.htmlTag.find(".icon_property").replaceWith(this.channelTree.client.fileManager.icons.generateTag(this.properties.virtualserver_icon_id).addClass("icon_property"));
|
||||
} else if(variable.key.indexOf('hostbanner') != -1) {
|
||||
|
|
Loading…
Reference in New Issue