X-Git-Url: http://git.euphorik.ch/?a=blobdiff_plain;f=js%2FpageMinichat%2FpageMinichat.js;h=c1276c7cfa56be9f0c6cbfd22bd2e130d8da46c5;hb=09608ab29e1c39ea51b51a5f8669dcde36efb306;hp=b71efeaac7ebae27438714ca5bb7f1c391d26e22;hpb=8ee1535f5594573931ddaebee77bf6148a5358cb;p=euphorik.git diff --git a/js/pageMinichat/pageMinichat.js b/js/pageMinichat/pageMinichat.js index b71efea..c1276c7 100755 --- a/js/pageMinichat/pageMinichat.js +++ b/js/pageMinichat/pageMinichat.js @@ -18,21 +18,18 @@ /*jslint laxbreak:true */ -euphorik.PageMinichat = function(client, formateur, util, communication) { +euphorik.PageMinichat = function(client, formater, util, communication) { this.nom = "minichat"; this.client = client; - this.formateur = formateur; + this.formater = formater; this.util = util; this.communication = communication; - this.commandes = new euphorik.Commandes(this.client, this, this.util, this.formateur); + this.commandes = new euphorik.Commandes(this.client, this, this.util, this.formater); // permet d'éviter d'envoyer plusieurs messages simultanément en pressant // rapidement sur "enter" par exemple this.envoieMessageEnCours = false; - - this.regexMessageTagMatch = /\{.*?\}>/g; - this.regexMessageTagReplace = /^(.*?\{.*?\}>)*/; }; euphorik.PageMinichat.prototype.contenu = function() { @@ -69,7 +66,7 @@ euphorik.PageMinichat.prototype.charger = function() { $("#posterMessage input.pseudo").val(this.client.pseudo); // cet appel ne doit pas être fait avant l'appel à 'charger' - this.conversations = new euphorik.Conversations(this.client, this.formateur, this.util, this.fragment); + this.conversations = new euphorik.Conversations(this.client, this.formater, this.util, this.fragment); this.chargerConversationsFragment(); @@ -123,12 +120,12 @@ euphorik.PageMinichat.prototype.charger = function() { // $("body").append('
'); // affichage des smiles - $("#smiles").append(this.formateur.getSmilesHTML()).children().each( + $("#smiles").append(this.formater.getSmilesHTML()).children().each( function(i) { var opacityBase = $(this).css("opacity"); $(this).click( function() { - thisPage.util.replaceSelection($("form#posterMessage input.message")[0], thisPage.formateur.smiles[$(this).attr("class")][0].source.replace(/\\/g, "")); + thisPage.util.replaceSelection($("form#posterMessage input.message")[0], thisPage.formater.smiles[$(this).attr("class")][0].source.replace(/\\/g, "")); } ).hover( function() { $(this).animate({opacity: 1}, 200); }, @@ -232,7 +229,7 @@ euphorik.PageMinichat.prototype.envoyerMessage = function(message) { var pseudo = $("form#posterMessage input.pseudo").val(); // (un pseudo vide est autorisé) - pseudo = this.formateur.filtrerInputPseudo(pseudo); + pseudo = this.formater.filtrerInputPseudo(pseudo); if (pseudo === euphorik.conf.pseudoDefaut) { this.util.messageDialogue("Le pseudo ne peut pas être " + euphorik.conf.pseudoDefaut);