diff --git a/js/FileManager.ts b/js/FileManager.ts index 6a58f041..e810a223 100644 --- a/js/FileManager.ts +++ b/js/FileManager.ts @@ -311,7 +311,7 @@ class IconManager { if(id == 0) return $("
"); else if(id < 1000) - return $(""); + return $(""); let tag = $.spawn("div"); tag.addClass("icon_empty"); @@ -342,7 +342,7 @@ class IconManager { }); }).catch(reason => { console.error("Could not load icon " + id + ". Reason: " + reason); - loader.removeClass("icon_loading").addClass("icon client-warning").attr("tag", "Could not load icon " + id); + loader.removeClass("icon_loading").addClass("icon manager-warning").attr("tag", "Could not load icon " + id); }); } @@ -447,7 +447,7 @@ class AvatarManager { }).catch(reason => { console.error("Could not load avatar for " + client.clientNickName() + ". Reason: " + reason); //TODO Broken image - loader.addClass("icon client-warning").attr("tag", "Could not load avatar " + client.clientNickName()); + loader.addClass("icon manager-warning").attr("tag", "Could not load avatar " + client.clientNickName()); }); } diff --git a/js/InfoBar.ts b/js/InfoBar.ts index c9392eb9..cbad5cde 100644 --- a/js/InfoBar.ts +++ b/js/InfoBar.ts @@ -162,7 +162,7 @@ class InfoBar { .css("display", "flex") .css("margin-top", "5px") .css("align-items", "center"); - $.spawn("div").addClass("icon client-permission_server_groups").appendTo(header); + $.spawn("div").addClass("icon manager-permission_server_groups").appendTo(header); $.spawn("div").text("Server groups:").css("margin-left", "3px").css("font-weight", "bold").appendTo(header); header.appendTo(serverGroups); @@ -196,7 +196,7 @@ class InfoBar { .css("display", "flex") .css("margin-top", "10px") .css("align-items", "center"); - $.spawn("div").addClass("icon client-permission_channel").appendTo(header); + $.spawn("div").addClass("icon manager-permission_channel").appendTo(header); $.spawn("div").text("Channel group:").css("margin-left", "3px").css("font-weight", "bold").appendTo(header); header.appendTo(channelGroup); @@ -227,7 +227,7 @@ class InfoBar { { let spawnTag = (type: string, description: string) : JQuery => { return $.spawn("div").css("display", "inline-flex") - .append($.spawn("div").addClass("icon_x32 client-" + type).css("margin-right", "5px")) + .append($.spawn("div").addClass("icon_x32 manager-" + type).css("margin-right", "5px")) .append($.spawn("a").text(description).css("align-self", "center")); }; diff --git a/js/chat.ts b/js/chat.ts index 6d884fb2..59631f89 100644 --- a/js/chat.ts +++ b/js/chat.ts @@ -184,7 +184,7 @@ class ChatEntry { tag.append("" + this._name + ""); let closeTag = $.spawn("div"); - closeTag.addClass("btn_close icon client-tab_close_button"); + closeTag.addClass("btn_close icon manager-tab_close_button"); if(!this._closeable) closeTag.hide(); tag.append(closeTag); @@ -208,7 +208,7 @@ class ChatEntry { if(_this.closeable) { actions.push({ type: MenuEntryType.ENTRY, - icon: "client-tab_close_button", + icon: "manager-tab_close_button", name: "Close", callback: () => { chat.deleteChat(_this); @@ -218,7 +218,7 @@ class ChatEntry { actions.push({ type: MenuEntryType.ENTRY, - icon: "client-tab_close_button", + icon: "manager-tab_close_button", name: "Close all private tabs", callback: () => { //TODO Implement this? @@ -266,18 +266,18 @@ class ChatEntry { if(this._unread) { switch (this.type) { case ChatType.CLIENT: - return "client-new_chat"; + return "manager-new_chat"; } } switch (this.type) { case ChatType.SERVER: - return "client-server_log"; + return "manager-server_log"; case ChatType.CHANNEL: - return "client-channel_chat"; + return "manager-channel_chat"; case ChatType.CLIENT: - return "client-player_chat"; + return "manager-player_chat"; case ChatType.GENERAL: - return "client-channel_chat"; + return "manager-channel_chat"; } return ""; } diff --git a/js/connection.ts b/js/connection.ts index f055a05b..bcfa93b1 100644 --- a/js/connection.ts +++ b/js/connection.ts @@ -515,7 +515,7 @@ class ConnectionCommandHandler { let tree = this.connection._client.channelTree; let client = tree.findClient(json["clid"]); if(!client) { - console.error("Unknown client left!"); + console.error("Unknown manager left!"); return 0; } if(client == this.connection._client.getClient()) { @@ -558,7 +558,7 @@ class ConnectionCommandHandler { json["reasonmsg"] ); } else { - console.error("Unknown client left reason!"); + console.error("Unknown manager left reason!"); } tree.deleteClient(client); @@ -572,16 +572,16 @@ class ConnectionCommandHandler { let channel_from = tree.findChannel(json["cfid"]); if(!client) { - console.error("Unknown client move (Client)!"); + console.error("Unknown manager move (Client)!"); return 0; } if(!channel_to) { - console.error("Unknown client move (Channel to)!"); + console.error("Unknown manager move (Channel to)!"); return 0; } if(!channel_from) //Not critical - console.error("Unknown client move (Channel from)!"); + console.error("Unknown manager move (Channel from)!"); let self = client instanceof LocalClientEntry; if(self) { @@ -669,11 +669,11 @@ class ConnectionCommandHandler { let invoker = this.connection._client.channelTree.findClient(json["invokerid"]); let target = this.connection._client.channelTree.findClient(json["target"]); if(!invoker) { //TODO spawn chat (Client is may invisible) - console.error("Got private message from invalid client!"); + console.error("Got private message from invalid manager!"); return; } if(!target) { //TODO spawn chat (Client is may invisible) - console.error("Got private message from invalid client!"); + console.error("Got private message from invalid manager!"); return; } if(invoker == this.connection._client.getClient()) { @@ -693,7 +693,7 @@ class ConnectionCommandHandler { let client = this.connection._client.channelTree.findClient(json["clid"]); if(!client) { - console.error("Tried to update an non existing client"); + console.error("Tried to update an non existing manager"); return; } diff --git a/js/load.ts b/js/load.ts index 79e52670..f2921677 100644 --- a/js/load.ts +++ b/js/load.ts @@ -113,7 +113,7 @@ function loadRelease() { awaitLoad(loadScripts([ //Load general API's ["js/assembly/TeaWeb-Identity.js"], - ["js/client.min.js", "js/client.js", "generated/js/client.min.js", "generated/js/client.js"] + ["js/manager.min.js", "js/manager.js", "generated/js/manager.min.js", "generated/js/manager.js"] ])).then(() => { console.log("Loaded successfully all scripts!"); app.callbackApp(); @@ -147,7 +147,7 @@ function loadDebug() { "js/ui/modal/ModalChangeVolume.js", "js/ui/modal/ModalBanClient.js", "js/ui/channel.js", - "js/ui/client.js", + "js/ui/manager.js", "js/ui/MusicClient.js", "js/ui/server.js", "js/ui/view.js", @@ -173,7 +173,7 @@ function loadDebug() { "js/contextMenu.js", "js/connection.js", "js/FileManager.js", - "js/client.js", + "js/manager.js", "js/chat.js", "js/InfoBar.js", "js/Identity.js" diff --git a/js/ui/ControlBar.ts b/js/ui/ControlBar.ts index a7f31d22..f8e01e71 100644 --- a/js/ui/ControlBar.ts +++ b/js/ui/ControlBar.ts @@ -61,11 +61,11 @@ class ControlBar { if(flag) { if(!tag.hasClass("activated")) tag.addClass("activated"); - tag.find(".icon_x32").attr("class", "icon_x32 client-input_muted"); + tag.find(".icon_x32").attr("class", "icon_x32 manager-input_muted"); } else { if(tag.hasClass("activated")) tag.removeClass("activated"); - tag.find(".icon_x32").attr("class", "icon_x32 client-capture"); + tag.find(".icon_x32").attr("class", "icon_x32 manager-capture"); } @@ -87,11 +87,11 @@ class ControlBar { if(flag) { if(!tag.hasClass("activated")) tag.addClass("activated"); - tag.find(".icon_x32").attr("class", "icon_x32 client-output_muted"); + tag.find(".icon_x32").attr("class", "icon_x32 manager-output_muted"); } else { if(tag.hasClass("activated")) tag.removeClass("activated"); - tag.find(".icon_x32").attr("class", "icon_x32 client-volume"); + tag.find(".icon_x32").attr("class", "icon_x32 manager-volume"); } if(this.handle.serverConnection.connected) diff --git a/js/ui/MusicClient.ts b/js/ui/MusicClient.ts index a61c985c..32a04786 100644 --- a/js/ui/MusicClient.ts +++ b/js/ui/MusicClient.ts @@ -18,19 +18,19 @@ class MusicClientEntry extends ClientEntry { spawnMenu(x, y, { name: "Change bot name", - icon: "client-change_nickname", + icon: "manager-change_nickname", disabled: true, callback: () => {}, type: MenuEntryType.ENTRY }, { name: "Change bot description", - icon: "client-edit", + icon: "manager-edit", disabled: true, callback: () => {}, type: MenuEntryType.ENTRY }, { name: "Open music panel", - icon: "client-edit", + icon: "manager-edit", disabled: true, callback: () => {}, type: MenuEntryType.ENTRY @@ -38,7 +38,7 @@ class MusicClientEntry extends ClientEntry { MenuEntry.HR(), { name: "Delete bot", - icon: "client-delete", + icon: "manager-delete", disabled: true, callback: () => {}, type: MenuEntryType.ENTRY diff --git a/js/ui/channel.ts b/js/ui/channel.ts index d8868209..c62a9b09 100644 --- a/js/ui/channel.ts +++ b/js/ui/channel.ts @@ -143,7 +143,7 @@ class ChannelEntry { this._tag_channel.addClass(this._channelAlign); //For left let channelType = $.spawn("div"); - channelType.addClass("channel_only_normal channel_type icon client-channel_green_subscribed"); + channelType.addClass("channel_only_normal channel_type icon manager-channel_green_subscribed"); this._tag_channel.append(channelType); this._tag_channel.append($.spawn("div").addClass("channel_name_container").append($.spawn("a").addClass("channel_name").text(this.channelName()))); @@ -153,16 +153,16 @@ class ChannelEntry { iconTag.appendTo(this._tag_channel); //Default icon (4) - iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_default icon client-channel_default").attr("title", "Default channel"))); + iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_default icon manager-channel_default").attr("title", "Default channel"))); //Password icon (3) - iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_password icon client-register").attr("title", "The channel is password protected"))); + iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_password icon manager-register").attr("title", "The channel is password protected"))); //Music icon (2) - iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_music icon client-music").attr("title", "Music quality"))); + iconTag.append($.spawn("div").addClass("channel_only_normal").append($.spawn("div").addClass("icon_entry icon_music icon manager-music").attr("title", "Music quality"))); //Channel Icon (1) iconTag.append($.spawn("div").addClass("channel_only_normal").addClass("icon_entry channel_icon").attr("title", "Channel icon")); //Default no sound (0) let container = $.spawn("div"); - let noSound = $.spawn("div").addClass("icon_entry icon_no_sound icon client-conflict-icon").attr("title", "You don't support the channel codec"); + let noSound = $.spawn("div").addClass("icon_entry icon_no_sound icon manager-conflict-icon").attr("title", "You don't support the channel codec"); let bg = $.spawn("div") .width(10) .height(14) @@ -290,7 +290,7 @@ class ChannelEntry { spawnMenu(x, y, { type: MenuEntryType.ENTRY, - icon: "client-channel_switch", + icon: "manager-channel_switch", name: "Switch to channel", callback: () => { this.joinChannel(); @@ -299,7 +299,7 @@ class ChannelEntry { MenuEntry.HR(), { type: MenuEntryType.ENTRY, - icon: "client-channel_edit", + icon: "manager-channel_edit", name: "Edit channel", invalidPermission: !channelModify, callback: () => { @@ -312,7 +312,7 @@ class ChannelEntry { }, { type: MenuEntryType.ENTRY, - icon: "client-channel_delete", + icon: "manager-channel_delete", name: "Delete channel", invalidPermission: !flagDelete, callback: () => this.channelTree.client.serverConnection.sendCommand("channeldelete", {cid: this.channelId}) @@ -320,13 +320,13 @@ class ChannelEntry { MenuEntry.HR(), { type: MenuEntryType.ENTRY, - icon: "client-channel_create_sub", + icon: "manager-channel_create_sub", name: "Create sub channel", invalidPermission: !(channelCreate && this.channelTree.client.permissions.neededPermission(PermissionType.B_CHANNEL_CREATE_CHILD).granted(1)), callback: () => this.channelTree.spawnCreateChannel(this) }, { type: MenuEntryType.ENTRY, - icon: "client-channel_create", + icon: "manager-channel_create", name: "Create channel", invalidPermission: !channelCreate, callback: () => this.channelTree.spawnCreateChannel() @@ -441,7 +441,7 @@ class ChannelEntry { else type = "green"; - tag.addClass("client-channel_" + type + "_subscribed"); + tag.addClass("manager-channel_" + type + "_subscribed"); } createChatTag(braces: boolean = false) : JQuery { diff --git a/js/ui/client.ts b/js/ui/client.ts index 74d7235a..5832016f 100644 --- a/js/ui/client.ts +++ b/js/ui/client.ts @@ -108,7 +108,7 @@ class ClientEntry { spawnMenu(x, y, { type: MenuEntryType.ENTRY, - icon: "client-change_nickname", + icon: "manager-change_nickname", name: "Open text chat", callback: function () { chat.activeChat = _this.chat(true); @@ -116,12 +116,12 @@ class ClientEntry { } }, { type: MenuEntryType.ENTRY, - icon: "client-poke", - name: "Poke client", + icon: "manager-poke", + name: "Poke manager", callback: function () { - createInputModal("Poke client", "Poke message: