From a3acf09bc350e0be7ac38dd234c2cdd79f0746b0 Mon Sep 17 00:00:00 2001 From: WolverinDEV Date: Sat, 23 Jun 2018 23:17:45 +0200 Subject: [PATCH] Removed obsolet tmpl function --- js/proto.ts | 1 - js/ui/modal/ModalBanClient.ts | 2 +- js/ui/modal/ModalChangeVolume.ts | 2 +- js/ui/modal/ModalCreateChannel.ts | 2 +- js/ui/modal/ModalSettings.ts | 2 +- templates.html | 2 +- 6 files changed, 5 insertions(+), 6 deletions(-) diff --git a/js/proto.ts b/js/proto.ts index 1a5e1910..94449414 100644 --- a/js/proto.ts +++ b/js/proto.ts @@ -6,7 +6,6 @@ interface Array { } interface JQuery { - tmpl(values?: any) : JQuery; render(values?: any) : string; renderTag(values?: any) : JQuery; } diff --git a/js/ui/modal/ModalBanClient.ts b/js/ui/modal/ModalBanClient.ts index 99c83671..407e792f 100644 --- a/js/ui/modal/ModalBanClient.ts +++ b/js/ui/modal/ModalBanClient.ts @@ -9,7 +9,7 @@ namespace Modals { return "Ban client"; }, body: function () { - let tag = $("#tmpl_client_ban").tmpl({ + let tag = $("#tmpl_client_ban").renderTag({ client_name: name }); diff --git a/js/ui/modal/ModalChangeVolume.ts b/js/ui/modal/ModalChangeVolume.ts index 3d366881..d07baca1 100644 --- a/js/ui/modal/ModalChangeVolume.ts +++ b/js/ui/modal/ModalChangeVolume.ts @@ -11,7 +11,7 @@ namespace Modals { return header; }, body: function () { - let tag = $("#tmpl_change_volume").tmpl(); + let tag = $("#tmpl_change_volume").renderTag(); tag.find(".volume_slider").on("change",_ => updateCallback(tag.find(".volume_slider").val())); tag.find(".volume_slider").on("input",_ => updateCallback(tag.find(".volume_slider").val())); //connect_address diff --git a/js/ui/modal/ModalCreateChannel.ts b/js/ui/modal/ModalCreateChannel.ts index 29875ee6..d48845ac 100644 --- a/js/ui/modal/ModalCreateChannel.ts +++ b/js/ui/modal/ModalCreateChannel.ts @@ -6,7 +6,7 @@ namespace Modals { const modal = createModal({ header: channel ? "Edit channel" : "Create channel", body: () => { - let template = $("#tmpl_channel_edit").tmpl(channel ? channel.properties : new ChannelProperties()); + let template = $("#tmpl_channel_edit").renderTag(channel ? channel.properties : new ChannelProperties()); template = $.spawn("div").append(template); return template.tabify(); }, diff --git a/js/ui/modal/ModalSettings.ts b/js/ui/modal/ModalSettings.ts index 4b812b69..b59d49cf 100644 --- a/js/ui/modal/ModalSettings.ts +++ b/js/ui/modal/ModalSettings.ts @@ -9,7 +9,7 @@ namespace Modals { modal = createModal({ header: "Settings", body: () => { - let template = $("#tmpl_settings").tmpl(); + let template = $("#tmpl_settings").renderTag(); template = $.spawn("div").append(template); initialiseSettingListeners(modal,template = template.tabify()); return template; diff --git a/templates.html b/templates.html index 9acee66e..13c8a7e8 100644 --- a/templates.html +++ b/templates.html @@ -323,7 +323,7 @@ if(this.current_selected.properties.client_input_muted) spawnTag("input_muted", "Microphone Muted").appendTo(this._htmlTag); --> -