Updates
parent
c34cb97cb7
commit
5b0e73dcff
|
@ -311,7 +311,7 @@ class IconManager {
|
|||
if(id == 0)
|
||||
return $("<div class='icon_empty'></div>");
|
||||
else if(id < 1000)
|
||||
return $("<div class='icon client-group_" + id + "'></div>");
|
||||
return $("<div class='icon manager-group_" + id + "'></div>");
|
||||
|
||||
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());
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -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"));
|
||||
};
|
||||
|
||||
|
|
16
js/chat.ts
16
js/chat.ts
|
@ -184,7 +184,7 @@ class ChatEntry {
|
|||
tag.append("<a class='name'>" + this._name + "</a>");
|
||||
|
||||
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 "";
|
||||
}
|
||||
|
|
|
@ -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;
|
||||
}
|
||||
|
||||
|
|
|
@ -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"
|
||||
|
|
|
@ -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)
|
||||
|
|
|
@ -18,19 +18,19 @@ class MusicClientEntry extends ClientEntry {
|
|||
spawnMenu(x, y,
|
||||
{
|
||||
name: "<b>Change bot name</b>",
|
||||
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
|
||||
|
|
|
@ -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: "<b>Switch to channel</b>",
|
||||
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 {
|
||||
|
|
|
@ -108,7 +108,7 @@ class ClientEntry {
|
|||
spawnMenu(x, y,
|
||||
{
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-change_nickname",
|
||||
icon: "manager-change_nickname",
|
||||
name: "<b>Open text chat</b>",
|
||||
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:<br>", text => true, result => {
|
||||
createInputModal("Poke manager", "Poke message:<br>", text => true, result => {
|
||||
if(result) {
|
||||
console.log("Poking client " + _this.clientNickName() + " with message " + result);
|
||||
console.log("Poking manager " + _this.clientNickName() + " with message " + result);
|
||||
_this.channelTree.client.serverConnection.sendCommand("clientpoke", {
|
||||
clid: _this.clientId(),
|
||||
msg: result
|
||||
|
@ -132,10 +132,10 @@ class ClientEntry {
|
|||
}
|
||||
}, {
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-edit",
|
||||
icon: "manager-edit",
|
||||
name: "Change description",
|
||||
callback: function () {
|
||||
createInputModal("Change client description", "New description:<br>", text => true, result => {
|
||||
createInputModal("Change manager description", "New description:<br>", text => true, result => {
|
||||
if(result) {
|
||||
console.log("Changing " + _this.clientNickName() + "'s description to " + result);
|
||||
_this.channelTree.client.serverConnection.sendCommand("clientedit", {
|
||||
|
@ -149,8 +149,8 @@ class ClientEntry {
|
|||
},
|
||||
MenuEntry.HR(), {
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-move_client_to_own_channel",
|
||||
name: "Move client to your channel",
|
||||
icon: "manager-move_client_to_own_channel",
|
||||
name: "Move manager to your channel",
|
||||
callback: () => {
|
||||
this.channelTree.client.serverConnection.sendCommand("clientmove", {
|
||||
clid: this.clientId(),
|
||||
|
@ -159,12 +159,12 @@ class ClientEntry {
|
|||
}
|
||||
}, {
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-kick_channel",
|
||||
name: "Kick client from channel",
|
||||
icon: "manager-kick_channel",
|
||||
name: "Kick manager from channel",
|
||||
callback: function () {
|
||||
createInputModal("Kick client from channel", "Kick reason:<br>", text => true, result => {
|
||||
createInputModal("Kick manager from channel", "Kick reason:<br>", text => true, result => {
|
||||
if(result) {
|
||||
console.log("Kicking client " + _this.clientNickName() + " from channel with reason " + result);
|
||||
console.log("Kicking manager " + _this.clientNickName() + " from channel with reason " + result);
|
||||
_this.channelTree.client.serverConnection.sendCommand("clientkick", {
|
||||
clid: _this.clientId(),
|
||||
reasonid: ViewReasonId.VREASON_CHANNEL_KICK,
|
||||
|
@ -176,12 +176,12 @@ class ClientEntry {
|
|||
}
|
||||
}, {
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-kick_server",
|
||||
name: "Kick client fom server",
|
||||
icon: "manager-kick_server",
|
||||
name: "Kick manager fom server",
|
||||
callback: function () {
|
||||
createInputModal("Kick client from server", "Kick reason:<br>", text => true, result => {
|
||||
createInputModal("Kick manager from server", "Kick reason:<br>", text => true, result => {
|
||||
if(result) {
|
||||
console.log("Kicking client " + _this.clientNickName() + " from server with reason " + result);
|
||||
console.log("Kicking manager " + _this.clientNickName() + " from server with reason " + result);
|
||||
_this.channelTree.client.serverConnection.sendCommand("clientkick", {
|
||||
clid: _this.clientId(),
|
||||
reasonid: ViewReasonId.VREASON_SERVER_KICK,
|
||||
|
@ -193,8 +193,8 @@ class ClientEntry {
|
|||
}
|
||||
}, {
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-ban_client",
|
||||
name: "Ban client",
|
||||
icon: "manager-ban_client",
|
||||
name: "Ban manager",
|
||||
invalidPermission: !this.channelTree.client.permissions.neededPermission(PermissionType.I_CLIENT_BAN_MAX_BANTIME).granted(1),
|
||||
callback: () => {
|
||||
Modals.spawnBanClient(this.properties.client_nickname, (duration, reason) => {
|
||||
|
@ -209,7 +209,7 @@ class ClientEntry {
|
|||
MenuEntry.HR(),
|
||||
{
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-volume",
|
||||
icon: "manager-volume",
|
||||
name: "Change Volume",
|
||||
callback: () => {
|
||||
Modals.spawnChangeVolume(this.audioController.volume, volume => {
|
||||
|
@ -287,13 +287,13 @@ class ClientEntry {
|
|||
let icon: string = "";
|
||||
let clicon: string = "";
|
||||
if(this.properties.client_away) {
|
||||
icon = "client-away";
|
||||
icon = "manager-away";
|
||||
} else if(this.properties.client_output_muted) {
|
||||
icon = "client-hardware_output_muted";
|
||||
icon = "manager-hardware_output_muted";
|
||||
} else if(!this.properties.client_input_hardware) {
|
||||
icon = "client-hardware_input_muted";
|
||||
icon = "manager-hardware_input_muted";
|
||||
} else if(this.properties.client_input_muted) {
|
||||
icon = "client-input_muted";
|
||||
icon = "manager-input_muted";
|
||||
} else {
|
||||
if(this._speaking) {
|
||||
if(this.properties.client_is_channel_commander)
|
||||
|
@ -335,7 +335,7 @@ class ClientEntry {
|
|||
this.properties[variable.key] = parseInt(variable.value);
|
||||
else
|
||||
this.properties[variable.key] = variable.value;
|
||||
group.log("Updating client " + this.clientId() + ". Key " + variable.key + " Value: '" + variable.value + "' (" + typeof (this.properties[variable.key]) + ")");
|
||||
group.log("Updating manager " + this.clientId() + ". Key " + variable.key + " Value: '" + variable.value + "' (" + typeof (this.properties[variable.key]) + ")");
|
||||
if(variable.key == "client_nickname") {
|
||||
this.tag.find(".name").text(variable.value);
|
||||
let chat = this.chat(false);
|
||||
|
@ -464,7 +464,7 @@ class LocalClientEntry extends ClientEntry {
|
|||
private renaming: boolean;
|
||||
|
||||
constructor(handle: TSClient) {
|
||||
super(0, "local client");
|
||||
super(0, "local manager");
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
|
@ -474,12 +474,12 @@ class LocalClientEntry extends ClientEntry {
|
|||
spawnMenu(x, y,
|
||||
{
|
||||
name: "<b>Change name</b>",
|
||||
icon: "client-change_nickname",
|
||||
icon: "manager-change_nickname",
|
||||
callback: () =>_self.openRename(),
|
||||
type: MenuEntryType.ENTRY
|
||||
}, {
|
||||
name: "Change description",
|
||||
icon: "client-edit",
|
||||
icon: "manager-edit",
|
||||
callback: () => {
|
||||
createInputModal("Change own description", "New description:<br>", text => true, result => {
|
||||
if(result) {
|
||||
|
|
|
@ -6,7 +6,7 @@ namespace Modals {
|
|||
export function spawnBanClient(name: string, callback: (length: number, reason: string) => void) {
|
||||
const connectModal = createModal({
|
||||
header: function() {
|
||||
return "Ban client";
|
||||
return "Ban manager";
|
||||
},
|
||||
body: function () {
|
||||
let tag = $("#tmpl_client_ban").tmpl({
|
||||
|
|
|
@ -32,7 +32,7 @@ class ServerEntry {
|
|||
|
||||
tag.attr("id", "server");
|
||||
tag.addClass("server");
|
||||
tag.append($.spawn("div").addClass("server_type icon client-server_green"));
|
||||
tag.append($.spawn("div").addClass("server_type icon manager-server_green"));
|
||||
tag.append($.spawn("a").addClass("name").text(this.properties.virtualserver_name));
|
||||
|
||||
const serverIcon = $("<span/>");
|
||||
|
|
|
@ -39,7 +39,7 @@ class ChannelTree {
|
|||
spawnMenu(x, y,
|
||||
{
|
||||
type: MenuEntryType.ENTRY,
|
||||
icon: "client-channel_create",
|
||||
icon: "manager-channel_create",
|
||||
name: "Create channel",
|
||||
invalidPermission: !channelCreate,
|
||||
callback: () => this.spawnCreateChannel()
|
||||
|
@ -167,7 +167,7 @@ class ChannelTree {
|
|||
|
||||
insertClient(client: ClientEntry, channel: ChannelEntry) : ClientEntry {
|
||||
let newClient = this.findClient(client.clientId());
|
||||
if(newClient) client = newClient; //Got new client :)
|
||||
if(newClient) client = newClient; //Got new manager :)
|
||||
else
|
||||
this.clients.push(client);
|
||||
client.channelTree = this;
|
||||
|
|
|
@ -240,7 +240,7 @@ class VoiceConnection {
|
|||
//console.log("Client id " + clientId + " PacketID " + packetId + " Codec: " + codec);
|
||||
let client = this.client.channelTree.findClient(clientId);
|
||||
if(!client) {
|
||||
console.error("Having voice from unknown client? (ClientID: " + clientId + ")");
|
||||
console.error("Having voice from unknown manager? (ClientID: " + clientId + ")");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -262,7 +262,7 @@ class VoiceConnection {
|
|||
codecPool.ownCodec(clientId)
|
||||
.then(decoder => decoder.decodeSamples(client.getAudioController().codecCache(codec), encodedData))
|
||||
.then(buffer => client.getAudioController().playBuffer(buffer)).catch(error => {
|
||||
console.error("Could not playback client's (" + clientId + ") audio (" + error + ")");
|
||||
console.error("Could not playback manager's (" + clientId + ") audio (" + error + ")");
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -280,7 +280,7 @@ class VoiceConnection {
|
|||
//TODO Use channel codec!
|
||||
this.codecPool[4].ownCodec(this.client.getClientId())
|
||||
.then(encoder => encoder.encodeSamples(this.client.getClient().getAudioController().codecCache(4),data));
|
||||
//this.client.getClient().getAudioController().play(data);
|
||||
//this.manager.getClient().getAudioController().play(data);
|
||||
}
|
||||
|
||||
private handleVoiceEnded() {
|
||||
|
|
Loading…
Reference in New Issue